Last active
December 7, 2015 15:08
-
-
Save rajikaimal/5736f6c560bc3edd6c52 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
//es5 | |
app.get('home',function(req,res){ | |
res.json({name: 'Rajika', universe: 'DC'}); | |
}); | |
//es6 arrow functions | |
app.get('home',(req,res) => { | |
res.json({name: 'Rajika', universe: 'DC'}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment