{
"compilerOptions": {
"target": "es5",//編譯后的目標
"lib": [
"dom", //dom運行環境
"dom.iterable",//迭代器運行環境
"esnext"//es6轉化成es5的環境
],
"downlevelIteration": true,
"allowJs": true, //是否允許在ts文件中引入js
"skipLibCheck": true,//是否跳過聲明文件的檢查
"esModuleInterop": true, //可以使用es6的方式導入node.js的方法
"allowSyntheticDefaultImports": true,
"strict": true,//所有的語法都會進行嚴格的檢查
"forceConsistentCasingInFileNames": true,//文件名是否區分大小寫
"module": "esnext",//模塊化標准
"moduleResolution": "node",//按照node的規則去找文件
"resolveJsonModule": true,//是否允許把json文件當做模塊進行解析
"isolatedModules": true,//每個文件需要是一個模塊
"noEmit": true, //不需要生成文件
"jsx": "react"
},
"include": [
"src" //處理src目錄下的文件
]
}