-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor tsconfigs to share compiler options
This lets each config specify *only* how it actually does a build (or not!), while sharing the config explicitly. It also fixes an existing bug in the compilation settings which was not affecting *normal* TS compilation with `tsc`, but was generating noise in the `broccoli-typescript-compiler` pipeline because the packages happened to be resolved in a different order such that the `loader` "package" definition, and its declaration of the `require` module, was not present in the graph. Set it explicitly in `compilerOptiosn.paths` to fix that.
- Loading branch information
1 parent
9c4962b
commit 4e62cd6
Showing
3 changed files
with
41 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,5 @@ | ||
# Set the default behavior, in case people don't have core.autocrlf set. | ||
* text=auto | ||
* text=auto | ||
|
||
# Tell GH to render all tsconfigs in the tsconfig dir correctly. | ||
tsconfig/*.json linguist-language=JSON-with-Comments |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,9 @@ | ||
{ | ||
"extends": "./tsconfig/compiler-options.json", | ||
"compilerOptions": { | ||
// Compilation Configuration | ||
"target": "es2017", | ||
"sourceMap": true, | ||
"outDir": "dist", | ||
"baseUrl": "packages", | ||
"rootDir": "packages", | ||
|
||
// Environment Configuration | ||
"experimentalDecorators": true, | ||
"moduleResolution": "node", | ||
|
||
// Enhance Strictness | ||
"strict": true, | ||
"noImplicitReturns": true, | ||
"allowUnreachableCode": false, | ||
"noPropertyAccessFromIndexSignature": true, | ||
"noUnusedLocals": true, | ||
"noUncheckedIndexedAccess": true, | ||
"noUnusedParameters": true, | ||
"esModuleInterop": false, | ||
"allowSyntheticDefaultImports": false, | ||
|
||
"newLine": "LF", | ||
"noEmit": true, | ||
|
||
"allowJs": true, | ||
"checkJs": false, | ||
|
||
"paths": { | ||
"backburner": ["../node_modules/backburner.js/dist/backburner.d.ts"] | ||
} | ||
"noEmit": true | ||
}, | ||
|
||
"include": ["packages/**/*.ts"], | ||
|
||
"exclude": ["dist", "node_modules", "tmp", "types"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
{ | ||
"$schema": "https://json.schemastore.org/tsconfig", | ||
"compilerOptions": { | ||
// Compilation Configuration | ||
"target": "es2019", | ||
"sourceMap": true, | ||
"baseUrl": "../packages", | ||
"rootDir": "../packages", | ||
|
||
// Environment Configuration | ||
"experimentalDecorators": true, | ||
"moduleResolution": "node", | ||
|
||
// Enhance Strictness | ||
"strict": true, | ||
"noImplicitReturns": true, | ||
"allowUnreachableCode": false, | ||
"noPropertyAccessFromIndexSignature": true, | ||
"noUnusedLocals": true, | ||
"noUncheckedIndexedAccess": true, | ||
"noUnusedParameters": true, | ||
"esModuleInterop": false, | ||
"allowSyntheticDefaultImports": false, | ||
|
||
"newLine": "LF", | ||
|
||
"allowJs": true, | ||
"checkJs": false, | ||
|
||
"paths": { | ||
"backburner": ["../node_modules/backburner.js/dist/backburner.d.ts"], | ||
"require": ["./loader/lib/index.d.ts"] | ||
} | ||
} | ||
} |