如何停止 jsx
当运行开发服务器时,NextJS将'react'属性覆盖为'preservation'?
我的 tsconfig.json
文件。
"compilerOptions": {
"target": "es5",
"lib": [
"dom",
"dom.iterable",
"esnext"
],
"allowJs": true,
"skipLibCheck": true,
"strict": false,
"forceConsistentCasingInFileNames": true,
"noEmit": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "node",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve"
},
"exclude": [
"node_modules"
],
"include": [
"next-env.d.ts",
"**/*.ts",
"**/*.tsx"
]
}
AFAIK的jsx选项必须是: react
编制我的 tsx
文件到 jsx
.
在这里回答。
https:/github.comkulshekharts-jestissues937
本质上,你延长了当前的 tsconfig.json
戏称一下 tsconfig.json
从你 jest.config.js
.