es6-arrow-functions-Q&A Flashcards
1
Q
What is the syntax for defining an arrow function?
A
parameters => {expression}
(parameter1, parameter2) => {expression}
2
Q
When an arrow function’s body is left without curly braces, what changes in its functionality?
A
If theres no curly braces around the expression the function will be implicitly returned
3
Q
How is the value of this determined within an arrow function?
A
This will be defined by the parent scope