JavaScript ES6 is the latest version available( as of 2021/June/1) since 2015. It’s also known as ES6 and ECMAScript 2015. So many awesome features were introduced with ES6, to make programmers work easy.

Here a list of some features that came with ES6. If you are looking for the full specification of ECMAScript 6 please visit from  here.

  • The let keyword
  • The const keyword
  • Array.find()
  • Array.findIndex()
  • New Number Methods
  • New Global Methods
  • JavaScript Modules
  • JavaScript Arrow Functions
  • JavaScript For/of
  • New Math Methods
  • New Number Properties
  • JavaScript Classes
  • JavaScript Promises
  • JavaScript Symbol
  • Default Parameters
  • Function Rest Parameter

That sure is a long list. So, today let’s talk about some of the top features from this list.

  • The let keyword
  • The const keyword
  • JavaScript Arrow Functions
  • JavaScript Classes
  • Template literals
  • Freeze Objects
  • Destructuring
  • Promises

You can also read: Top JavaScript Frameworks For Developers .

const and let Keywords

Before ES6 there was only one way to declare variables in JS and that was with the var keyword. ES6 introduced let and const .

const and let works almost the same way. But with const you can declare constants(Read-only), so the variables declared as constants will be read-only. But this does not affect object properties or array elements.

When you declare a variable outside any function it’s global scoped. It can be accessed from anywhere in the program. When a variable is declared inside a function it’s said to be function scoped (ex: let and const).

#javascript #es6 #js #modern-javascript

Modern JavaScript Features That Every Programmer Must Know..!
1.35 GEEK