Skip to content

Instantly share code, notes, and snippets.

@bogas04
Created March 16, 2018 18:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bogas04/d1a50321c0fd932678552f8cf65812b7 to your computer and use it in GitHub Desktop.
Save bogas04/d1a50321c0fd932678552f8cf65812b7 to your computer and use it in GitHub Desktop.
/*
* Use const > let > var
* Use functional way whenever possible
* Optimize only when necessary (you test and find the bottleneck part).
* Prefer pure functions that return rather than mututate global values.
* Destructing to write cleaner code
* Spread rest for clean code
* Object short hands
* Promises, Promise.all, Promise.race
* async await is good!
* import/export
Mozilla Developer Network
*/
// ECMASCript: http://2ality.com/ ECMAScript
// ES5
// arr.map/filter/reduce/some/every
// ES2015
// let/const/Promises/destructuring/array spread|rest
// ES2016
// a ** 2
// ES2017
// async await
// ES2018
// Object spread|rest
// Future: https://github.com/tc39/proposals
// VSCode Editor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment