|
4 | 4 | "display": "Shared node base", |
5 | 5 |
|
6 | 6 | "compilerOptions": { |
| 7 | + "allowImportingTsExtensions": true, |
7 | 8 | "moduleResolution": "node", |
8 | 9 |
|
9 | 10 | // "module": "NodeNext", |
10 | 11 | "module": "esnext", // pulumi complains of es2022 |
11 | 12 | "target": "esnext", // pulumi complains of es2022 |
12 | 13 |
|
| 14 | + |
13 | 15 | // ---- |
14 | 16 | // https://github.com/sindresorhus/tsconfig/blob/main/tsconfig.json |
15 | 17 | "lib": ["dom", "dom.iterable", "es2020"], |
16 | | - |
| 18 | + |
17 | 19 | "allowSyntheticDefaultImports": true, // To provide backwards compatibility, Node.js allows you to import most CommonJS packages with a default import. This flag tells TypeScript that it's okay to use import on CommonJS modules. |
18 | 20 | "resolveJsonModule": true, |
19 | | - |
| 21 | + |
20 | 22 | // ---- |
21 | 23 | // from node18 base, but changed lib/module/target |
22 | 24 | "strict": true, |
23 | 25 | "esModuleInterop": true, |
24 | 26 | "skipLibCheck": true, |
25 | 27 | "forceConsistentCasingInFileNames": true, |
26 | | - |
| 28 | + |
27 | 29 | // ---- |
28 | 30 | // Our alterations to the base |
29 | 31 | // "allowSyntheticDefaultImports": true, |
30 | | - |
| 32 | + |
31 | 33 | // Ensure that .d.ts files are created by tsc |
32 | 34 | "declaration": true, |
33 | | - // Do not allow js |
34 | | - "allowJs": false, |
| 35 | + "allowJs": true, |
| 36 | + "maxNodeModuleJsDepth": 10, |
35 | 37 | // No js, ts, maps when errors are reported |
36 | 38 | "noEmitOnError": true, |
37 | 39 | // Do not allow inference to fall back to any type |
|
40 | 42 | "noImplicitReturns": true, |
41 | 43 | // Report errors on unused local variables. |
42 | 44 | "noUnusedLocals": false, |
| 45 | + // Resolve JSON modules for imports |
| 46 | + "resolveJsonModule": true, |
43 | 47 | // obj[foo] suppression |
44 | 48 | // "suppressImplicitAnyIndexErrors": true, -- deprecated in 5.0 |
45 | 49 |
|
|
0 commit comments