请问下老师我的项目里代码全部使用tsc编译。我想让ts让babel一样可以编译我的Promise拥有Promise的polyfill。查阅官网我发现配置lib库就可以解决。但是我这么配置后发现还是无效。
{
"exclude": [
"node_modules",
"**/*.stories.tsx",
"**/*.test.tsx"
],
"include": [
"./lib/"
],
"compilerOptions": {
"target": "es5",
"lib": ["dom", "ESNext", "es5", "es2015.promise"],
"jsx": "react",
"module": "ESNext",
"moduleResolution": "node",
"baseUrl": "./",
"paths": {},
"allowJs": false,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"strict": true,
"skipLibCheck": true,
"isolatedModules": true,
"alwaysStrict": true,
"declaration": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"allowSyntheticDefaultImports": true,
"outDir": "./types"
}
}
请问老师我应该如何处理呢