Last active
March 26, 2020 20:48
-
-
Save fazzyA/828726a88a0986811a349c1b456a2096 to your computer and use it in GitHub Desktop.
arrow functions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// simple function | |
function add(a,b){ | |
return a+b | |
} | |
//similar arrow function | |
const add = (a,b) => { | |
return a+b | |
} | |
//shorten it more | |
const add = (a,b) => a+b |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment