在我的翻译代码中,我看到了:
var __decorate = undefined && undefined.__decorate || function (decorators, target, key, desc) { // ...
undefined && undefined.__decorate
应该永远是假的。
__decorate
. 我的预感是
undefined
是
一些变量,并在构建时用一个值交换。
我的问题是:为什么不删除永远的虚假表达?
多亏了
@Matt McCutchen
,
Typescript本身有一个
this
引用,提及
here
.
那么,也许巴贝尔在用这个做什么?