Skip to content

Latest commit

 

History

History
35 lines (25 loc) · 570 Bytes

File metadata and controls

35 lines (25 loc) · 570 Bytes
sidebarDepth categories tags
0
TypeScript
TSLint
TypeScript

array-type

统一数组类型声明方式:简单类型的数组必须使用 T[], 复杂类型的数组必须使用 Array<T | S>

  • 本规范中的配置:

"array-type": [true, "array-simple"]

const foo: Array<T>;
const bar: (T & S)[];
const foo: T[];
const bar: Array<T & S>;