r/node • • Dec 17 '18

JavaScript Functions - 4 Ways

Post image
715 Upvotes

87 comments sorted by

View all comments

15

u/ENx5vP Dec 17 '18

You may omit the arrow function parentheses.

6

u/[deleted] Dec 17 '18

[removed] — view removed comment

8

u/virtulis Dec 17 '18

exactly one parameter.

Kotlin's { a, b -> c } lambdas looked weird to me at first but being able to just write { stuff } looks much better than () => stuff