TSC—版本2.8.3
在我的firebase项目中,从根本上来说
tsconfig.json
如下所示;
{
"compilerOptions": {
/* Basic Options */
"target": "es5",
"module": "commonjs",
"outDir": "./",
"types": ["mocha"],
"sourceMap": true,
"project": "/**/*.ts",
"watch": true,
"strict": true
},
"exclude": ["node_modules", "typings/browser.d.ts", "typings/browser"]
}
在下面的文件夹里
test.ts
文件如下;
app-firebase\functions\Repositories\test.ts
代码:
abstract class AnimalAbstract {
abstract makeSound(): void;
move(): void {
console.log("roaming the earth...");
}
}
如果我跑
tsc
在根文件夹中,它不会将文件编译到
.js
. 但是如果我导航到文件夹并运行
tsc test.ts
它编译。
我也试着移除
project
参数输入
config
文件,但没有起作用。
我怎么能做到
watch
整个项目文件夹?