DEV Community

Discussion on: The Complete Guide to Destructuring in JavaScript

Collapse
 
kosich profile image
Kostia Palchyk

Nice article!

Also, worth mentioning, one can use spread operator in Object destruction:

const { a, ...rest } = { a: 1, other: 2 };
// a:      1;
// rest: { other: 2 }

es2018, I think