Fat Arrow Functions JavaScript Programming Tutorial

Lesson Code: http://www.developphp.com/video/JavaScript/Fat-Arrow-Functions-JavaScript-Programming-Tutorial

Crash course on using the new Arrow functions in JavaScript, introduced in ECMAscript Edition 6 to provide a new approach to writing anonymous functions. Arrow functions have 2 major advantages over traditional anonymous functions. (a) They reduce the amount of code you need to write. (b) In object oriented programming, the “this” keyword always refers to the object no matter how many anonymous functions are nested in the class. We will demonstrate these concepts through code right now starting with the most basic.

They are Anonymous functions. Anonymous functions are functions that have no name like normal functions do. We see them used as parameters in methods that expect exectuable code as an argument. Anonymous functions are used in object oriented programming, or they are sometimes supplied as the value of a named variable.

We will compare traditional Anonymous function syntax with arrow function syntax side by side using several simple examples in order to demonstrate where, when and how to use arrow functions where you normally use anonymous functions.


ranjan kumar says:

very clearly explained, i liked it, thanks Adam 😀

Stephan Stanisic says:

And then he realized; “var _ = x = document.getElementById(x);”

Jemmeli Nejmeddine says:

thank you too much , great explanation for a major annoying aspect of javascript coding .

Hariharan R says:

Awesome explanation !!

Cleiton Lopes says:


Ilan Kushnir says:

Great explanation! thanks!

Srini Padavala says:

Explained very well. Fantastic.

Bobby L says:

That was very clear and understandable. Thanks!!

Ahmad Aziz says:

Which website can i read more about this?

Javier Guerrero says:

Such great content. Thank you so much for taking the time to create it. Do you happen to have a patron to support your work? Thanks

Dardo Ariel Landa says:

Excellent!!!! Thanks you very much : )

mtssvnsn says:

Nice explanation!

But i have to say, that I’m hating all these new fancy syntaxes.
I’m pretty sure the world is much better off without them, and all other changes

Could it be because I’m over 40?
I guess we will never know.

Thomas Orlita says:

Awesome, good job!

Julius Cool says:

Awesome tutorial Adam…

Ratel 2 says:

looks exactly the same as lambda expression in C#. Can I call it like that cause I got used to it or it’s wrong? Another thing is that you have mentioned it may be not supported in older browsers. Can I use it when writing my JS or not really cause older browsers will not run it? If I can’t what is the point of using it?

Dr. Evil says:

I wish I could see the disliker just so I knew if it was a bot or a troll or maybe a just a pessimist. I think it’s much more productive to find the videos you like and then like them, unless the video is extremely or very bad, you should not dislike.
P.S. I also really enjoy these videos please make more.

Nabeel Tahir says:

can you make a tutorial on image upload database but datatype in databse is longblob or show image from databse……and store 5 image at a time and show 5 image

Mer Igos says:

In your opinion sir Adam. Which I must focus to study function() or () => …
Thank you for the tut sir!

Merridi Stokes says:

Thanks for the info… I am writing some scripts for my pages and this will come in handy. Thanks again.

Lucas Paiano says:

Simply excellent, thaks!

Jon Grant says:

Great explanation! Thanks for making this video!

wonders Johnson says:

this is lovely,now my problem of icons have been solved.thanks my web master

Larry Sunshine says:

I see you started using Notepad++ instead of that crappy Dreamweaver 🙂

Eldin Edy says:

cool man, well explained!! thanks!

Carlos Gonzalez says:

Thank you very much!

Henry Le Berre says:

why did you use notepad ++ ?

Roman Semchuk says:

Thank you for an elegant and simple explanation!

Emily Maidman says:

This is a great tutorial. On a different note though, arrow functions make code so much harder to read, which bearing in mind we all spend so much more time reading code than we do typing code, I don’t think the arrow function is the great addition to the language a lot of people think it is going to be.

Colton Colcleasure says:

Thank you, buddy. Great video, easy to understand for novices.

Julio Vergara says:

Well explained sir, thanks a lot

Todd Mcfarlin says:

Nice job, very clear and concise

Ray Carl Brown-Amory says:

you are great guy love your tutorials

ETXAlienRobot201 says:

thanks for this tutorial.

(due to a stupid miss-click, i lost what i was just typing, so try 2) not impressed with the way they continue to “fix” or “update” this stuff…

another shorthand thing?
does it really affect performance is the question…
I somehow doubt it will help with the massive and resource-intensive scripts that most websites now run.

And then how these arrow functions magically recognize the correct reference to “this” …
What I see /hear of this usage is: “don’t use this old, dirty hack. Use this new and improved, gold-plated one, instead!”

Seems to me it’d make more sense to make the existing functions behave properly, instead… >.>
Whether or not it’s more compact, or performs better… at the end of the day, it’s simply another hack to learn, and more confusion to be had.

Also another feature to have its standardization and implementation varied in some way.

This feature sounds more like depreciating the html tag with the tag, that behaves EXACTLY THE SAME, than any real improvement. The only difference here is the replacement has like one difference in functionality that is beneficial to the still very hacked-together way that JavaScript implements OOP.

I’m glad people like you exist, to explain these things clearly, but overall, I’m not impressed with the latest, poorly documented, and selectively implemented “standards” that keep popping-up. This is one reason many game devs especially continue to use Flash, it’s less convoluted, and for the most part, Adobe doesn’t re-invent the wheel and create hacks to repair bugs. They actually UPDATE their code, fix the bugs, and overall, improve their system. IDK what exactly the W3C and other organizations that literally govern how websites and web content should be developed are thinking, but I question the bulk of it. They continue to deliver a half-baked product and expect everyone to just buy right into it. They claim Flash and Java are outdated and obsolete, but these languages by far continue to evolve much more than their own, ANCIENT languages.

I’ll keep what you’ve just explained in mind, but I feel there are a few other updates JavaScript needs a LOT more than these new arrow functions.

Map Maverick says:

Nice tutorial. Thanks you rockstar!

victorighalo says:

Thank you so much. I’ve been learning from your videos for years now nd I have been greatly blessed by them. Thank you for sacrificing your time to teach us.

premier69 says:

is it true that ES6 VAR should be Let whenever possible?

jasonc_tutorials says:

nice tutorial man. Did you get babel to work? LOLs. Well you can upgrade to windows 10 and edge should have es2015 working.

link2pk says:

Hi @Adam, Isn’t Car a constructor function(not class) in javascript?

Samesh Wijeweera says:

Awesome very clear thanks

dhg1234 says:

looks like lambda expression.

David Jimenez says:


HarkCitizens says:

Great tutorial!

PIP HK says:

You made the hard simple! Great thanks!

Cristian-Alexandru Radu says:

please do more ECMA6 script tutorials based

it’s very interesting, but so far, I didn’t know how to use them 😀

Nabeel Tahir says:

can you make a tutorial on image upload database but datatype in databse is longblob or show image from databse……and store 5 image at a time and show 5 image

Ming Dinkleburg says:

Subbed, great video, helped a lot!

vikram srinivas says:


Martin Ransome says:

Your tutorial was excellent except executable is pronounced ExE_CUTE_ABLE. You are a genius. Do you have any tutorials on http transactions?

Manuel Ramos says:

Very clearly exposed. Congratulations!

 Write a comment


Do you like our videos?
Do you want to see more like that?

Please click below to support us on Facebook!