Skip to content

Commit 18ea8be

Browse files
authored
Specify typeroot (#4892)
This prevents tsc from picking up random types from parent directories such as in situations like an element-web layered build, and generally seems like good hygiene as we don't want to pick up random types from whatever directory we happen to be checked out into.
1 parent 4f9ca2c commit 18ea8be

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tsconfig.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
"declaration": true,
1111
"strict": true,
1212
"allowImportingTsExtensions": true,
13-
"lib": ["es2024"]
13+
"lib": ["es2024"],
14+
"baseUrl": ".",
15+
"typeRoots": ["./node_modules/@types"]
1416
},
1517
"include": ["./src/**/*.ts", "./spec/**/*.ts"]
1618
}

0 commit comments

Comments
 (0)