Course overview
ECMAScript was created to standardize JavaScript which is its main implementation. ECMAScript is the most used language for writing web client scripts and for writing Node.js server applications.
At the end of this course you will know the major functionalities of ECMAScript which will allow you to create modern, robust and modular web or back-end applications.
This course, updated for ECMAScript 2019, covers ECMAScript from version ECMAScript 2015 (ES6) up to ECMAScript 2019.
Target audience
- Identify and have a general knowledge of ECMAScript and JavaScript
- Know the evolution process of ECMAScript
- Know the contributions of ECMAScript standards since ECMAScript 2015 (ES6)
Prerequisites
Developers, integrators, software architects, technical project managers
Course Outline
- Basic knowledge of HTML
- Have taken the course ‘JavaScript: language fundamentals’ or have equivalent knowledge
1 Introduction to the ECMAScript standard
- A brief history of ECMAScript
- JavaScript vs ECMAScript
- ECMA International, the TC39 committee and the ECMAScript evolution process
- The main features of ECMAScript, from the beginnings to today
- Compatibility of web browsers and Node.js with ECMAScript
- Transpilation and backward compatibility
Workshops:
- Exploring compatibility tools: caniuse, kangax,…
- Configuring an ECMAScript development environment and using a transpiler
2 The basics of ECMAScript
- Declaration of variables and temporal dead zone
- Code blocks
- Scopes
- Strict mode and ECMAScript
Workshops:
- Using ‘let’ and ‘const’
- Case study: scopes
3 Operators and parameters
- Exponentiation
- Destructuring
- Rest
- Spread
- Functions: parameters default values
- Functions: named parameters
- Functions: multiple return values
Workshops:
- Using the new operators ‘rest’, ‘spread’ and ‘destructuring’
- Using operators with functions
4 Template Literals
- String interpolation
- Multi-line strings
- Tagged template literals and tag functions
Workshops:
- Using character string interpolation instead of concatenation
- Using a DSL with tagged template literals
5 Arrow Functions
- Definition and syntax of arrow functions
- Syntactic traps
- Lexical variables
Workshops:
- Using pipeline collection with Arrow Functions
- Case studies: events handlers, classes
6 OOP and Classes
- Evolutions of the literal object syntax
- Object methods
- Class declaration and instantiation of objects
- Classes vs Constructor Function and prototypes
- Method Definitions
- Heritage
- Static methods
Workshops:
- Class definition and derivation
- Creation of custom errors by extending/subclassing Error
7 Asynchronous programming
- Asynchronous JavaScript programming reminders: call stack, callbacks, event loop
- Promises
- Async/await and asynchronous functions
- Error handling in asynchronous programs
Workshops:
- Creation and use of promises
- Chain and composition of promises
- Writing asynchronous code with async functions
8 Symbols
- What are symbols
- Use case for symbols
- The symbol API
Workshops:
- Creation and use of symbols
9 Iterators and Generators
- The Iterable interface and iterables
- The iterator interface
- For-of loop and other language constructs to iterate
- Generators
- Generators as iterators, observers, coroutines
- Asynchronous iterators and generators
- Asynchronous and for-await-of iteration
Workshops:
- Using and implementing iterables
- Using generators
10 Modules
- Modules fundamentals in JavaScript
- Detailed study of Import and Export
- Use of ES6 modules in browsers
Workshops:
- Modularization of an existing code base
11 Collections, structured data and types
- Set
- Map
- Typed Arrays and memory model
- Evolution of types: String, Array, Object, Number and Math, RegExp…
Workshops:
- Using data types and structures
12 Reflection
- The Reflect object
- Proxy objects
Workshops:
- Meta-programming with proxies