@ edx/ typescript- config
关于
在目录中存在 tsconfig.json 文件,表明目录是TypeScript工程的根. tsconfig.json 文件指定了编译工程所需的根文件和编译器选项(来自 https://www.typescriptlang.org/docs/handbook/tsconfig-json.html 互联网档案馆的存檔,存档日期2014-12-22) (中文(简体) ).
安装
npx install-peerdeps --dev @edx/typescript-config
这将安装软件包及其所有对等依赖 .
使用量
在仓库中创建文件 tsconfig.json,带有条款 "extends": "@edx/typescript-config",添加对根目录、输出目录和目录的引用,以包含/排除TypeScript汇编.
{
"extends": "@edx/typescript-config",
"compilerOptions": {
"rootDir": ".",
"outDir": "dist"
},
"include": ["src/**/*"],
"exclude": ["dist", "node_modules"]
}