DEV Community

Discussion on: ES6 Arrow Function Syntax Explained Simply

Collapse
 
amt8u profile image
amt8u

About hoisiting for arrow functions: Arrow functions are not defined as function declarations. Instead they are always assigned as function expression to a variable.

Thus the regular rule for variable hoisting(let, const and var) comes into picture. It has nothing to do with arrow function syntax.