July 2019
Intermediate to advanced
416 pages
10h 6m
English
Where we used spread operators to build up an object, we can also deconstruct objects with something called a REST property. Deconstructing simply means that we are going to take a complex thing and break it down into simpler ones. In other words, destructuring happens when we assign the elements inside an array or an object's properties to individual variables. While we have always been able to break complex objects and arrays down into simpler types, TypeScript provides a clean and elegant way to break these types down using REST parameters, which can deconstruct both objects and arrays.
In order to understand what REST properties are, we first need to understand how to deconstruct an object or ...
Read now
Unlock full access