Leave a Reply

12 Comments on "ECMAScript 6 / ES6 New Features – Tutorial 4 – Spread Operator"

Notify of
avatar

Tomáš Štrigner
Guest
Tomáš Štrigner
4 months 3 days ago

1st example is not a good one. It was possible to spread array as arguments to function/method before. And as a bonus, it was possible to calling it under specific scope via funct.apply(scope, [argsArray]) like: function addNumbers(a, b, c) {   console.log(a + b +c);}var nums = [3, 5, 7];addNumbers.apply({},nums);

priya harish
Guest
priya harish
7 months 24 days ago

I learnt PHP from you. Had been procrastinating learning es6.. BUT not anymore!! lots of love Bucky!! <3 #rolemodel

Lucas Shanley
Guest
Lucas Shanley
7 months 27 days ago

Bucky I freaking love your vids!!! This solves the problem I have been having recently! Thanks yet again for the many years of great content 🙂

Martin Soušek
Guest
Martin Soušek
9 months 15 days ago

Now what if number of parameters of the function does not match the array length?

candh
Guest
candh
1 year 2 months ago

what the fuck

Rashad Kokash
Guest
Rashad Kokash
1 year 3 months ago

Could you please make the font bigger in future videos 😀

Dankest Elf
Guest
Dankest Elf
1 year 3 months ago

what about the apply function?

Allison Graves
Guest
Allison Graves
1 year 3 months ago

best operator but need to get used to it

Abeltensor
Guest
Abeltensor
1 year 3 months ago

annoying I can't get the spread operator to work in webstorm. I'm using es6 and have the babel watcher running but it keeps throwing an error, any tips Bucky?

〈FireMan/〉
Guest
〈FireMan/〉
1 year 3 months ago

just food for thoughteval(array.join("+"))var meats = ["bacon","ham"]var food = ["apples", meats, "Kiwi","rice"]

〈FireMan/〉
Guest
〈FireMan/〉
1 year 3 months ago

they are all ways of doing what he does in the video with vanilla javascript

LJ
Guest
LJ
1 year 3 months ago

what?

wpDiscuz