Chapter 15 | Destructuring | Typescript | Angular Tutorial

preview_player
Показать описание

Destructuring syntax is an expression that unpacks values from arrays or properties of objects into distinct variables.

Example:
let arr = [1,2];
let [x, y] = arr;

Values in array are assigned to individual variables x and y.
Рекомендации по теме
welcome to shbcf.ru