Chapter 1. Playing with Syntax

JavaScript was lacking behind some other programming languages when compared to various syntactic forms such as declaring constant variables, declaring block scoped variables, extracting data from arrays, shorter syntax for declaring functions and so on. ES6 adds up a lot of new syntax-based features to JavaScript, which helps the developers to write less and do more. ES6 also prevents programmers from using various hacks for achieving various goals, which have negative performance impact and made code harder to read. In this chapter, we will look at the new syntactic features, introduced by ES6.

In this chapter, we'll cover:

  • Creating the block scoped variables using the let keyword
  • Creating constant variables using ...

Get React: Building Modern Web Applications now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.