Angular2 类型错误:无法读取未定义的属性"编译器选项"



我有TypeError:

无法读取未定义的属性

的属性'compileroptions'

这是我的编译代码:

{
  "compilerOptions": {
    "target": "ES5",
    "module": "commonjs",
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "sourceMap": true,
    "noEmitHelpers": true,
  },
  "compileOnSave": false,
  "buildOnSave": false,
  "awesomeTypescriptLoaderOptions": {
    "forkChecker": true,
    "useWebpackText": true
  }
}

有人可以告诉我为什么会发生这种情况吗?

首先,您的JSON格式在您的应用程序的.tsconfig.json中是错误的。第八行有一个,

"noEmitHelpers": true, // <-- trailing comma in tscofing breaks ts compile

相关内容

最新更新