使用vscode 创建一个 react+reducer项目时候,遇到以下警告
Experimental support for decorators is a feature that is subject to
change in a future release. Set the ‘experimentalDecorators’ option to
remove this warning.
解决办法:
在项目的根目录创建一个 tsconfig.json,配置如下:
{
"compilerOptions": {
"experimentalDecorators": true,
"allowJs": true
}
}
重新vscode即可