
...spread operator and rest operator - Beau teaches JavaScript
video description
Date: 2022-03-14
Related videos
Comments and reviews: 6
xganh
const arr1 = ['JAN', 'FEB', 'MAR', 'APR', 'MAY'];
var temp = [ (arr1) => - return [...arr1] - ]
console.log(temp) // says that this is a function
1) what is going on? i just wanna use an annonomous function to return the spread out array
2) pls help me !
3) Thank you!
reply
const arr1 = ['JAN', 'FEB', 'MAR', 'APR', 'MAY'];
var temp = [ (arr1) => - return [...arr1] - ]
console.log(temp) // says that this is a function
1) what is going on? i just wanna use an annonomous function to return the spread out array
2) pls help me !
3) Thank you!
reply
Dax
This video gives 100 times the useful information the website does, which isn't a great thing, since I expect many fewer will see this than will read the page on the rest operator. That said, you're excellent at explaining things. A very good teacher.
reply
This video gives 100 times the useful information the website does, which isn't a great thing, since I expect many fewer will see this than will read the page on the rest operator. That said, you're excellent at explaining things. A very good teacher.
reply
Filip
I remember being here, watching this video, doing some exercises. But here I am again, not having a slight idea what spread and rest operators are. fml
reply
I remember being here, watching this video, doing some exercises. But here I am again, not having a slight idea what spread and rest operators are. fml
reply
Assan
Thank you thanks you thank you. I was stuck after getting about 50% progress and I needed to redo the whole course because my fundamentals were wrong.
reply
Thank you thanks you thank you. I was stuck after getting about 50% progress and I needed to redo the whole course because my fundamentals were wrong.
reply
herolivesnu
Wow! You did a great job here in your explanations. I can't just pass without saying -God will continue to bless you with more knowledge-.
reply
Wow! You did a great job here in your explanations. I can't just pass without saying -God will continue to bless you with more knowledge-.
reply
Rock&Rocks
It seems to be a mistake as arr1.concat(arr2) will return [0, 1, 2]. It should be arr1 = arr1.concat(arr2) to return [0, 1, 2, 3, 4, 5]
reply
It seems to be a mistake as arr1.concat(arr2) will return [0, 1, 2]. It should be arr1 = arr1.concat(arr2) to return [0, 1, 2, 3, 4, 5]
reply
Add a review, comment
Other channel videos















