boolean、number、string

undefined、null

any、unknown、void

never

数组

元组

interface

class

枚举 (使用 联合类型 或 as const 替代)

联合类型 |

交叉类型 &

type

常用技巧

工具类型

断言(Assertion)

TypeScript 实用小知识: Nominal Typing(名义类型) / 品牌类型(Branded Types)

如何判断一个 any 类型any 类型?

Typescript 运行时数据校验

Select Option 转 Enum 枚举对象 https://github.com/shijistar/enum-plus

Tips

Powered by Fruition