TypeScript极速梳理


4.7. tuple

<p><code>tuple</code> 就是⼀个⻓度固定的数组。</p> <pre><code>let t: [string,number] t = ['hello',123] // 警告,不能将类型“[string, number, boolean]”分配给类型“[string, number]” t = ['hello',123,false]</code></pre>

页面列表

ITEM_HTML