我正在做一个VueJS项目.我们刚刚实现了TypeScrip (version 4.8.4).
在更新ts类型文件中的接口后,我收到此错误error TS5053: Option 'emitDeclarationOnly' cannot be specified with option 'noEmit'
.
在我的tsconfig
文件中,我们只声明了"emitDeclarationOnly": true,
,但看起来noEmit
与nodeMODULES下的其他包一起声明了.
以下是tsconfig文件的完整内容
{
"compilerOptions": {
"target": "es6",
"module": "es6",
"strict": true,
"jsx": "preserve",
"moduleResolution": "node",
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"forceConsistentCasingInFileNames": true,
"resolveJsonModule": true,
"sourceMap": true,
"noImplicitAny": false,
"baseUrl": ".",
"allowJs": true,
"experimentalDecorators": true,
"emitDecoratorMetadata": true,
"declaration": true,
"isolatedModules": true,
"emitDeclarationOnly": true,
"outDir": "tsdist",
"types": [
"webpack-env",
"jest"
],
"typeRoots": [
"./node_modules/@types",
],
"paths": {
"@/*": [
"src/*"
],
"AppCheckout/*": ["src/assets/scripts/AppComponent/Checkout/src/*"],
"AppCommon/*": ["src/assets/scripts/AppComponent/Common/src/*"],
"AppPublication/*": ["src/assets/scripts/AppComponent/Publication/src/*"],
"AppStore/*": ["src/assets/scripts/AppComponent/Store/src/*"]
},
"lib": [
"esnext",
"dom",
"dom.iterable",
"scripthost"
]
},
"include": [
"src/**/*.ts",
"src/**/*.tsx",
"src/**/*.vue",
"tests/**/*.ts",
"tests/**/*.tsx"
, "src/assets/scripts/globals/Container/Core/initContainer.js" ],
"exclude": [
"node_modules",
"./tasks"
],
"vueCompilerOptions": {
"target": 2.7
}
}