什么是 TypeScript 里的 Constructor signature
2021-06-23
阅读 2 分钟
5.4kJavaScript functions can also be invoked with the new operator. TypeScript refers to these as constructors because they usually create a new object. You can write a construct signature by adding the new keyword in front of a call signature: