ES6 The Modern Javascript
The world today is moving from Javascript to ECMAScript i.e. ES6, ES7, ES8, ES9, ES10 and so on. So what is ECMAScript is? How did it start? I have tried to explain everything in this article that I would have wanted to know when I was learning ES6.
Many Javascript developers today are very familiar with ES5 but I’ve seen that many are still not so familiar with the ES6, which is also known as the modern Javascript and also many are using awesome ES6 features in their javascript code without really knowing that it is ES6.
People do think that ECMAScript is a new language, people do start learning ES6 but never wondered if it is new then why ES6, not ES1, actually ECMAScript is not a new language, it is there since 1997. ECMA i.e. European Computer Manufacturer’s Association introduced ECMAScript in June 1997 to standardize the JavaScript programming language and ES6 is the sixth version of ECMAScript. I am not going to bore you by telling about each version of ECMAScript, for that you have Wikipedia but this article will go more around ES6 because it took almost 6 years after ES5 and got many syntaxes changed.
I repeat ECMAScript is just the standard, javascript is the implementation. The ECMAScript versions before ES6 are ES1, ES2, ES3, ES4, ES5, ES5.1. ES1, ES2, ES3 released in somewhat ’90s and ES4 got drafted around 2003, it was expected to release in 2008 but never got released because of some political differences between the different parties. ES5(2009) and ES5.1(2011) are you can say versions of JavaScript that you are most familiar with is you have started learning web development recently. Nowadays they are kinda moving from version numbers to years i.e. ES6 to ES2015 so if you hear somewhere ES2015 instead of ES6 are same just different nomenclature.
When people start to learn any JavaScript frameworks such as React, they find JavaScript as a whole new language because there has been a lot of syntax changes in ES6. So, before jumping into any framework it is necessary to understand the basic syntax of the ES6.
The latest version today of ECMAScript is ES10 or ECMAScript 2019 but still, there are browsers not supporting even ES6 so it doesn’t matter you have written code in ES6 or ES10 because at the end it is going to get converted into ES5 when it will run on the browser using transpiler such as Babel.
Babel is a free and open-source JavaScript transcompiler that is mainly used to convert ES6(ECMAScript2015)+ code into a backwards-compatible version of JavaScript i.e. ES5 that can be run by older JavaScript engines and help your ES6 code run in any browser across the world.
Mastering ES6 syntax can get you a position in web development and help you build that personal project you’ve been dreaming of. It’s a skill that will gonna put you more in demand in the modern web development industry, especially with the release of modern web frameworks like React and Angular 2.
ES6 is an in-depth series which has many features, that makes the life of a developer much easier. I just gave a brief introduction of ECMAScript and will try to write more articles explaining all the syntaxes of ES6. Hope it was useful.
Reading is good but reading with implementation is great !
Suggestions and critics about the article are most welcome.