ES6 (a): What is ES6?

Source: Internet
Author: User

Author Jason Orendorff GitHub home Page Https://github.com/jorendorff

What has changed in ECMAScript?

Programming language JavaScript is the implementation and extension of ECMAScript, and is being standardized by ECMA, a standard organization similar to the one. The ECMAScript defines:

    • Language grammar – Syntax parsing rules, keywords, statements, declarations, operators, and so on.
    • Type – Boolean, number, String, object, and so on.
    • Prototypes and inheritance
    • The standard library for built-in objects and functions –json, Math, array methods, object introspection methods, and so on.

The ECMAScript standard does not define the related functionality of HTML or CSS, nor does it define a Web API like the DOM (Document Object model), which is defined in a separate standard. ECMAScript covers the usage scenarios of JS in various environments, whether in a browser environment or a non-browser environment like node. js.

New Standard

Last week, the final draft of the 6th edition of the ECMAScript Language specification was brought to the ECMA Assembly for review, what does that mean?

This means we will have the latest JavaScript core language standards this summer.

This is undoubtedly a blockbuster news. As early as 2009, the previous version of ES5 just released, since then, the ES Standards Committee has been intensively preparing the new JS language standard--ES6.

ES6 is a major version upgrade, and while ES6 is adhering to the design concept of maximizing compatibility with existing code, the JS code you wrote in the past will continue to work. In fact, many browsers already support some of the ES6 features, and will continue to work to achieve the remaining features. This means that in some browsers that have implemented some features, your JS code is already working. If you have not met any compatibility issues so far, you will most likely not encounter these problems and the browser is rapidly implementing new features.

Version Number 6

The historical versions of the ECMAScript standard are 1, 2, 3, 5, respectively.

So why is there no 4th edition? In fact, in the past there have been plans to release the 4th edition of the huge new features, but eventually because of the idea too aggressive and then be abolished (this version of the standard has an extremely complex support for generics and type inference of the built-in static type System).

ES4 was controversial, and when the standard committee finally stopped developing ES4, its members agreed to release a relatively modest version of the ES5, and then continued to develop some more substantive new features. This definitive negotiation agreement is ultimately named "Harmony", so the ES5 specification contains two words:

Fulfilling commitments

Improved version ES5, released in 2009, introduced Object.create (), Object.defineproperty (), getters and setters, strict mode, and JSON objects. I've used all of these new features, and I really like the improvements ES5 made. But in fact, these improvements do not affect the way I write JS code, the biggest innovation for me is probably the new array method:. Map (),. Filter () these.

However, ES6 is not so! After a few years of sharpening, it has become the most substantive JS ever upgrade, the new language and library features like the Treasure of the Lord, waiting for insight to explore. The new language features cover a wide range of popular syntactic sugars, such as arrow functions and simple string interpolation (string interpolation), to the new concept of burning the brain, such as proxies (proxies) and generators (generators).

ES6 will completely change the way you write JS code!

This series is designed to show you how to carefully review these new features that ES6 provides to JavaScript programmers.

We'll start with a classic "omission feature" that I've been looking forward to seeing in JavaScript for ten years. So join us from now on and take a look at ES6 iterators (iterators) and the new for-of loop!

ES6 (a): What is ES6?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.