Shortly after the release of ES1, ES2 and ES3 were also release. ES4 however was much argued about and was eventually abandoned to give way to ES5 in 2009.
ES5 brought many new features with it. Some of the most well know are new array methods like
We now have an official specification for ES6.
What Are The New ES6 Features?
With ES6 we have new keywords for variable declaration like
const but the most exciting part according to me are the
arrow functions ,
template strings and default parameters.
One Important thing to note here is that when the ES6 spec was official in June 2015, it can not be implemented by browsers by a flick of a switch. Browser developers (such as Mozilla, Google,etc) will have to make changes and implement the new specified features. This can take Months if not years. And for the most parts is done in increments.
So how can you determine if your browser supports ES6 or not and if it does which features does it Support?
That’s easy head over to http://kangax.github.io/compat-table/es6/ there you will see supported features mentioned in green and not supported features in red. For comparison with ES5 you can visit http://kangax.github.io/compat-table/es5/ and see that it has a lot of green.
When Should You Use ES6?