19

What is ES6? Is it JavaScript? Or multiple language supporter?

I searched for it but can't understand it, especially the page on Wikipedia. Is it better than Javascript? And what can I do in my web developing using this language?

So what ES6 is, and how can I use it in my web app developing ?

androidnation
  • 335
  • 1
  • 2
  • 5
  • 2
    I'm voting to close this question as off-topic because it does not show a minimum level of research. "JavaScript (...) has been standardized in the [ECMAScript language specification](https://en.wikipedia.org/wiki/JavaScript)." ... "Well-known [implementations of the language, such as JavaScript](https://en.wikipedia.org/wiki/ECMAScript) (...) are widely used for client-side scripting on the Web." – Scant Roger Jan 10 '16 at 16:02

1 Answers1

24

ES6 is short-hand for EcmaScript 6, which is a deprecated name for the EcmaScript 2015 language specification. ES2015 is the 6th version of EcmaScript, thus why it was previously referred to as ES6. For reasons best known to themselves, those responsible for defining the language standard renamed it to ES2015 with the final version of the v6 spec.

EcmaScript is the "official" name for JavaScript. Now that ES2015 is finalised, it effectively just becomes JavaScript v6 to most people.

Aside from ES4, there is no real difference between JavaScript and EcmaScript. ES4 introduced classes and static typing and was the standard behind Flash's ActionScript 3, but it was never ratified as a JavaScript language, as it introduced too many breaking changes. It was eventually abandoned and ES3.1 became ES5, which is the JavaScript version used in the "HTML5" world.

David Arno
  • 38,972
  • 9
  • 88
  • 121
  • 2
    I didn't know JavaScript almost had types! Too bad the changes weren't accepted. – gardenhead Jan 08 '16 at 08:56
  • I believe TC39 has adopted a "rolling release" model where they will release whatever features are "ready" at a given constant rate, rather than fixing a set of features and releasing whenever the features are ready. I.e., they have moved from a fixed-feature-set-flexible-release-date model to a fixed-release-date-flexible-feature-set model. Given that, it makes sense change the release numbering to something including the date. Since it's unlikely that they will ever release two revisions within a year, "2015" is what they came up with. – Jörg W Mittag Jan 08 '16 at 10:16
  • @gardenhead: gradual typing is *still* an open research field. Language specifications are *not* the correct place for doing cutting edge research. JavaScript 2 / ECMAScript 4 were absolute *beasts* and horrible chimeras of languages, designed by responding to "feature requests" (rather constant whining) by Java programmers who don't understand the first thing about ECMAScript. It had prototypes *and* classes, completely separate from each other (I'm not talking about syntax sugar like in ES2015), with interfaces thrown in for good measure, static and dynamic types, literally everything … – Jörg W Mittag Jan 08 '16 at 10:19
  • … but the kitchen sink. Remember what Mads Torgersen once said about the C# design process and why they don't add all features to C#: "I wouldn't want to use a language that includes all features I would want to use in a language." – Jörg W Mittag Jan 08 '16 at 10:20
  • @JörgWMittag, ActionScript 3 implemented ES4. Whilst there are odd features to it (especially the whole weirdness around prototypes and classes), it's far from being a "horrible chimera of [a] language". There are far worse examples of over-featured languages. – David Arno Jan 08 '16 at 11:12