{
"outFile": {
"description": "Specify a file that bundles all outputs into one JavaScript file. If `declaration` is true, also designates a file that bundles all .d.ts output.",
"type": "string",
"markdownDescription": "Specify a file that bundles all outputs into one JavaScript file. If `declaration` is true, also designates a file that bundles all .d.ts output.\n\nSee more: https://www.typescriptlang.org/tsconfig#outFile"
},
"outDir": {
"description": "Specify an output folder for all emitted files.",
"type": "string",
"markdownDescription": "Specify an output folder for all emitted files.\n\nSee more: https://www.typescriptlang.org/tsconfig#outDir"
},
"rootDir": {
"description": "Specify the root folder within your source files.",
"type": "string",
"markdownDescription": "Specify the root folder within your source files.\n\nSee more: https://www.typescriptlang.org/tsconfig#rootDir"
},
}
// test.ts
console.log("Hello");
npx tsc
⇒ 최상위 경로에 test.js 생성!
// tsconfig.json
{
"outDir": "./dist",
"rootDir": "./src",
}
// src/test.ts
console.log("Hello");
npx tsc
⇒ dist/test.js 생성!
// tsconfig.json
{
"outDir": "./dist",
~~"rootDir": "./src",~~
}
// hello.ts
console.log("Hi");
npx tsc
⇒ dist/src/hello.js 생성!