What does 3 dots mean in typescript?

The three dots are known as the spread operator from Typescript (also from ES7). The spread operator return all elements of an array. Like you would write each element separately: let myArr = [1, 2, 3]; return [1, 2, 3]; //is the same as: return […myArr];

Sizin İçin Seçtik  How do you pass arguments in TypeScript?

Leave a Reply

Your email address will not be published. Required fields are marked *

What does 3 dots mean in typescript?

The three dots are known as the spread operator from Typescript (also from ES7). The spread operator return all elements of an array. Like you would write each element separately: let myArr = [1, 2, 3]; return [1, 2, 3]; //is the same as: return […myArr];

Sizin İçin Seçtik  Can you buy coins on Binance?

Leave a Reply

Your email address will not be published. Required fields are marked *