ECMAScript 6+ Basics II

Learn ECMAScript 6+ Basics II

🕓 Last updated today

Knowledge Check

Take this customized & interactive quiz to test your knowledge on ECMAScript 6+ Basics II, then check out the learning resources below.

Question 1 of 4

You have an object called userInfo which contains keys called name and birthdate. How do you destructure the name into the variable firstName?


Core Learning

The fastest way to learn ECMAScript 6+ Basics II is simply to study these exact resources. Focus on the 👀 to learn extra quickly and save time!

Array and Object Destructuring

👀 2 Things to Focus On

  • Pay special attention to using new variables names and default values
  • Be careful with nested destructuring when the value of the object is not consistent!

Rest and Spread Operators

👀 2 Things to Focus On

  • Use on both objects and arrays.
  • Much more elegant than using Object.assign()

Tricks to Combine Destructuring and Rest/Spread

👀 1 Thing to Focus On

  • Combine them together for maximum efficiency

Async/Await

👀 1 Thing to Focus On

  • Replace those gnarly Promise chains with elegant async/await code