Skip to content

Commit 80186c1

Browse files
authored
chore: rename tsconfigs for IDEs (#1524)
1 parent 6df29dc commit 80186c1

File tree

4 files changed

+17
-17
lines changed

4 files changed

+17
-17
lines changed

src/lib/tsconfig-spec.json renamed to src/lib/tsconfig-srcs.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"experimentalDecorators": true,
66
"lib": ["es6", "es2015", "dom"],
77
"mapRoot": "",
8-
"module": "commonjs",
8+
"module": "es2015",
99
"moduleResolution": "node",
1010
"noEmitOnError": true,
1111
"noImplicitAny": true,
@@ -15,18 +15,18 @@
1515
"target": "es5",
1616
"inlineSources": true,
1717
"stripInternal": true,
18-
"baseUrl": "",
19-
"paths": {
20-
},
2118
"typeRoots": [
2219
"../../node_modules/@types"
2320
],
2421
"types": [
25-
"jasmine"
2622
]
2723
},
24+
"exclude": [
25+
"**/*.spec.*",
26+
"system-config-spec.ts"
27+
],
2828
"angularCompilerOptions": {
29-
"genDir": "../../dist",
29+
"genDir": "../../dist/@angular/material",
3030
"skipTemplateCodegen": true,
3131
"debug": true
3232
}

src/lib/tsconfig.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"experimentalDecorators": true,
66
"lib": ["es6", "es2015", "dom"],
77
"mapRoot": "",
8-
"module": "es2015",
8+
"module": "commonjs",
99
"moduleResolution": "node",
1010
"noEmitOnError": true,
1111
"noImplicitAny": true,
@@ -15,18 +15,18 @@
1515
"target": "es5",
1616
"inlineSources": true,
1717
"stripInternal": true,
18+
"baseUrl": "",
19+
"paths": {
20+
},
1821
"typeRoots": [
1922
"../../node_modules/@types"
2023
],
2124
"types": [
25+
"jasmine"
2226
]
2327
},
24-
"exclude": [
25-
"**/*.spec.*",
26-
"system-config-spec.ts"
27-
],
2828
"angularCompilerOptions": {
29-
"genDir": "../../dist/@angular/material",
29+
"genDir": "../../dist",
3030
"skipTemplateCodegen": true,
3131
"debug": true
3232
}

tools/gulp/task_helpers.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,11 @@ function _globify(maybeGlob: string, suffix = '**/*') {
3434

3535

3636
/** Create a TS Build Task, based on the options. */
37-
export function tsBuildTask(tsConfigPath: string) {
37+
export function tsBuildTask(tsConfigPath: string, tsConfigName = 'tsconfig.json') {
3838
let tsConfigDir = tsConfigPath;
39-
if (fs.existsSync(path.join(tsConfigDir, 'tsconfig.json'))) {
39+
if (fs.existsSync(path.join(tsConfigDir, tsConfigName))) {
4040
// Append tsconfig.json
41-
tsConfigPath = path.join(tsConfigDir, 'tsconfig.json');
41+
tsConfigPath = path.join(tsConfigDir, tsConfigName);
4242
} else {
4343
tsConfigDir = path.dirname(tsConfigDir);
4444
}

tools/gulp/tasks/components.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,10 @@ task(':watch:components:spec', () => {
4040

4141

4242
/** Builds component typescript only (ESM output). */
43-
task(':build:components:ts', tsBuildTask(componentsDir));
43+
task(':build:components:ts', tsBuildTask(componentsDir, 'tsconfig-srcs.json'));
4444

4545
/** Builds components typescript for tests (CJS output). */
46-
task(':build:components:spec', tsBuildTask(path.join(componentsDir, 'tsconfig-spec.json')));
46+
task(':build:components:spec', tsBuildTask(componentsDir));
4747

4848
/** Copies assets (html, markdown) to build output. */
4949
task(':build:components:assets', copyTask([

0 commit comments

Comments
 (0)