Skip to content
This repository was archived by the owner on Jan 13, 2025. It is now read-only.

Commit c649de5

Browse files
author
Matt Goo
authored
fix: add strict true to tsconfig (#4286)
1 parent 6b958de commit c649de5

File tree

3 files changed

+16
-9
lines changed

3 files changed

+16
-9
lines changed

packages/mdc-dom/ponyfill.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ function closest(element: Element, selector: string): Element | null {
3535
return element.closest(selector);
3636
}
3737

38-
let el = element;
38+
let el: Element | null = element;
3939
while (el) {
4040
if (matches(el, selector)) {
4141
return el;

packages/mdc-linear-progress/foundation.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
* THE SOFTWARE.
2222
*/
2323

24-
import {getCorrectPropertyName, StandardCssPropertyName} from '@material/animation';
24+
import {getCorrectPropertyName, StandardCssPropertyName} from '@material/animation/index';
2525
import MDCFoundation from '@material/base/foundation';
2626
import {MDCLinearProgressAdapter} from './adapter';
2727
import {cssClasses, strings} from './constants';
@@ -48,9 +48,9 @@ export default class MDCLinearProgressFoundation extends MDCFoundation<MDCLinear
4848
};
4949
}
5050

51-
private isDeterminate_: boolean;
52-
private isReversed_: boolean;
53-
private progress_: number;
51+
private isDeterminate_!: boolean;
52+
private isReversed_!: boolean;
53+
private progress_!: number;
5454

5555
init() {
5656
this.isDeterminate_ = !this.adapter_.hasClass(cssClasses.INDETERMINATE_CLASS);

tsconfig.json

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,19 @@
11
{
22
"compilerOptions": {
33
"lib": ["es5", "es6", "dom"],
4-
"noEmitOnError": true,
5-
"noImplicitAny": true,
6-
"noImplicitThis": true,
4+
"downlevelIteration": true,
5+
"moduleResolution": "node",
6+
"experimentalDecorators": true,
7+
"emitDecoratorMetadata": true,
8+
"skipLibCheck": true,
9+
"noFallthroughCasesInSwitch": true,
710
"noUnusedLocals": true,
811
"noUnusedParameters": true,
9-
"alwaysStrict": true,
12+
"noErrorTruncation": true,
13+
"noEmitOnError": false,
14+
"importHelpers": true,
15+
"noStrictGenericChecks": true,
16+
"strict": true,
1017
"pretty": true,
1118
"preserveConstEnums": true,
1219
"stripInternal": true,

0 commit comments

Comments
 (0)