Get the App
SLTechnology News&Howtos  ›  Servers  › 

How to find out the relationship between JS, ES and TS

Shulou Source: shulou.com Published: 2022-05-31 20:03:08 09月17日 Update

How to find out the relationship between JS, ES, TS, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain in detail for you, people with this need can come to learn, I hope you can gain something.

Preface

I believe that many front-end partners are quite familiar with the word ECMAScript,JavaScript,TypeScript, which can be said to be the core technology of our work, but if you specifically ask what is the relationship between these three and what is the difference, I am afraid that like the editor, it is difficult to accurately describe them, so I decided to thoroughly understand their relationship and difference with you.

The relationship among the three ECMAScript

ECMAScript, the language defined by ECMA-262, is not limited to Web browsers. In fact, the language has no methods such as input and output.

ECMA-262 defines the language as a benchmark to build a more robust scripting language on top of it. At a basic level, ECMA-262 describes the following parts of the language, if not browsers:

Grammar

Types

Statement

Keyword

Reserved word

Operator

Global object

ECMAScript is just a term for a language that implements all aspects of the specification. In fact, it can also be understood as a language standard. JavaScript implements ECMAScript, while Adobe ActionScript also implements ECMAScript. If you want, you can also build a scripting language such as XXScript to implement ECMAScript.

JavaScript

Although JavaScript and ECMAScript are basically synonyms in everyday use, JavaScript is far from being limited to the parts defined by ECMA-262. The complete JavaScript implementation consists of the following parts:

Core (ECMAScript)

Document object Model (DOM)

Browser object Model (BOM)

It can be understood that ECMAScript is the scripting language that forms the foundation of JavaScript, together with DOM and BOM constitute a complete JavaScript implementation.

TypeScript

TypeScript is a superset of JavaScript, adding an optional static type system, many new ECMAScript features (such as decorators) that have not yet been officially released, and so on, which will eventually be compiled into JavaScript code.

ECMAScript is a standard language, JavaScript is the implementation of ECMAScript, and TypeScript is a superset of JavaScript. Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.

Tags: Languages objects browsers scripts browsing guys buddies standards cores models types parts one door superset help clarity parts facts in fact code Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Information Redmi Linux OPPO Reno vpn