Open boomsaas-customers opened 4 years ago
We need to fix this at https://github.com/SchemaStore/schemastore/blob/master/src/schemas/json/tsconfig.json
I don't think setting null
here is an intended thing, but probably you're not the only one relying on that behavior now, so we should add some explicit tests too
We also need to fix it in the commandLineParser
as well
@boomsaas-customers It seems, in your example, you missed "rootDir"
option, because without "rootDir"
, "outDir": ""
works correctly.
```shell 35642 - a - index.ts - tsconfig.json - b - index.ts - tsconfig.json - tsconfig.base.json ``` ```json // tsconfig.base.json { "compilerOptions": { "target": "es5", "module": "commonjs", "outDir": "dist" } } ``` --- ```ts // index.ts const a = null; ``` ```json // a/tsconfig.json { "extends": "../tsconfig.base" } ``` ```shell tsc -p ./a/tsconfig.json ``` ```shell cat dist/index.js "use strict"; var a = null; ``` --- ```ts // index.ts const b = null; ``` ```json // b/tsconfig.json { "extends": "../tsconfig.base", "outDir": "" } ``` ```shell tsc -p ./b/tsconfig.json ``` **Puts** results to **`b`** folder no to **`dist`** ```shell cat b/index.js "use strict"; var b = null; ```
@sheetalkamat Do you mean changing outDir
-" type" from "string "to" string" | null
?
cc @RyanCavanaugh
TypeScript Version: 3.7.2 Search Terms: Unset outDir in extended tsconfig outDir null outDir Type Code
Expected behavior: No warning inside VSCode.
Actual behavior:
I want to unset the outDir configuration inside my extended config to have the transpiled files next to their source files. Adding a string like "" would instead make them appear in the root folder though. Null seems to work fine.