June 14th, 2017: This article was updated to add new shorthand tips based on ES6. If you want to learn more about the changes in ES6, sign up for SitePoint Premium and check out our screencast A Look into ES6
1. The Ternary Operator
This is a great code saver when you want to write an if..else statement in just one line.
... read the whole story at www.sitepoint.com.