The Question : 584 people think this question is useful Arrow functions in ES2015 provide a more concise syntax. Can I replace all my function declarations / expressions with arrow functions now? What do I have to look out for? Examples: Constructor function Prototype methods Object (literal) methods Callbacks Variadic functions The Question Comments :
The Question : 602 people think this question is useful I can mark a javascript function as “async” (i.e. returning a promise) with the async keyword. Like this: What is the equivalent syntax for arrow functions? The Question Comments : It’s worth noting that at least firefox and babel does let you do that var
The Question : 665 people think this question is useful When returning an object from an arrow function, it seems that it is necessary to use an extra set of {} and a return keyword because of an ambiguity in the grammar. That means I can’t write p => {foo: "bar"}, but have to write