三毛

Results 5 issues of 三毛

https://devblogs.microsoft.com/typescript/announcing-typescript-4-0-beta/

planning

`tuple` to `union`: ```ts type ElementOf = T extends Array ? E : T type ATuple = ['hello', 'world']; type ToUnion = ElementOf; // 'hello' | 'world' ``` 另一种方法: ```ts...

如下代码所示: ```ts const TestDecorator = () => { return ( target: Object, key: string | symbol, descriptor: TypedPropertyDescriptor number> // 函数返回值必须是 number ) => { // ... } } class...

Tips

[FAQ](https://github.com/Microsoft/TypeScript/wiki/FAQ)

用 TS 重写以后,发现不能正常写单元测试了,官网上的那几个 demo 也跑不起来了。 不知 dalao 有什么想法?