Skip to content

Commit e6a25f4

Browse files
devversionmmalerba
authored andcommitted
build: bazel and gulp tsconfigs need to be in sync (#13707)
* Similar to how we did it for the CDK, the ts compilations through Bazel and Gulp should be as similar as possible in order to make the tests w/ Bazel creditable.
1 parent 985774a commit e6a25f4

File tree

4 files changed

+8
-28
lines changed

4 files changed

+8
-28
lines changed

src/bazel-tsconfig-build.json

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,5 @@
2424
"lib": ["es2015", "dom"],
2525
"skipLibCheck": true,
2626
"types": ["tslib"]
27-
},
28-
"bazelOptions": {
29-
"suppressTsconfigOverrideWarnings": true
3027
}
3128
}

src/cdk/tsconfig-build.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// TypeScript config file that is used to compile the cdk's ES2015 package through Gulp. As the
22
// long term goal is to switch to Bazel, and we already want to run tests with Bazel, we need to
3-
// ensure the TypeScript build options are the same for Gulp and Bazel. We archive this by
3+
// ensure the TypeScript build options are the same for Gulp and Bazel. We achieve this by
44
// extending the generic Bazel build tsconfig which will be used for each entry-point.
55
{
66
"extends": "../bazel-tsconfig-build.json",

src/lib/tsconfig-build.json

Lines changed: 6 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,17 @@
1-
// TypeScript config file that is used to compile the library into ES2015.
1+
// TypeScript config file that is used to compile the Material package through Gulp. As the
2+
// long term goal is to switch to Bazel, and we already want to run tests with Bazel, we need to
3+
// ensure the TypeScript build options are the same for Gulp and Bazel. We achieve this by
4+
// extending the generic Bazel build tsconfig which will be used for each entry-point.
25
{
6+
"extends": "../bazel-tsconfig-build.json",
37
"compilerOptions": {
4-
"declaration": true,
5-
"stripInternal": false,
6-
"experimentalDecorators": true,
7-
"noUnusedParameters": true,
8-
"strictNullChecks": true,
9-
"strictFunctionTypes": true,
10-
"noImplicitAny": true,
11-
"noImplicitThis": true,
12-
"importHelpers": true,
13-
"newLine": "lf",
14-
"module": "es2015",
15-
"moduleResolution": "node",
8+
"baseUrl": ".",
169
"outDir": "../../dist/packages/material",
1710
"rootDir": ".",
1811
"rootDirs": [
1912
".",
2013
"../../dist/packages/material"
2114
],
22-
"sourceMap": true,
23-
"inlineSources": true,
24-
"target": "es2015",
25-
"lib": ["es2015", "dom"],
26-
"skipLibCheck": true,
27-
"types": [],
28-
"baseUrl": ".",
2915
"paths": {
3016
"@angular/cdk/*": ["../../dist/packages/cdk/*"],
3117
"@angular/material/*": ["../../dist/packages/material/*"]
@@ -42,8 +28,5 @@
4228
"flatModuleId": "@angular/material",
4329
"skipTemplateCodegen": true,
4430
"fullTemplateTypeCheck": true
45-
},
46-
"bazelOptions": {
47-
"suppressTsconfigOverrideWarnings": true
4831
}
4932
}

src/lib/tsconfig-tests.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
// Unset options inherited from tsconfig-build
2323
"annotateForClosureCompiler": false,
2424
"flatModuleOutFile": null,
25-
"flatModuleId": null,
25+
"flatModuleId": null
2626
},
2727
"include": [
2828
"**/*.spec.ts",

0 commit comments

Comments
 (0)