[英]vscode: [ts] Experimental support for decorators is a feature that is subject to change
[英]VSCode Experimental Support for Decorators Warning When Trying to Create New Module
我剛剛安裝了 Angular 10 並將 VSCode 升級到最新。
創建新模塊時:
import { NgModule } from '@angular/core';
const mm = []
@NgModule({
imports: [ ...mm ],
exports: [...mm
],
providers: [
]
})
export class MaterialModule {
}
創建此裝飾器錯誤:
class MaterialModule
Experimental support for decorators is a feature that is subject to change in a future release. Set the 'experimentalDecorators' option in your 'tsconfig' or 'jsconfig' to remove this warning.ts(1219)
它只是為新模塊創建的。 現有的app.module.ts
沒有錯誤……所以有點混亂。
我在 VSCode 中卸載並重新安裝了“Angular Language Support”,就成功了。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.