-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtsconfig.json
More file actions
143 lines (143 loc) · 5.72 KB
/
Copy pathtsconfig.json
File metadata and controls
143 lines (143 loc) · 5.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
{
"$schema": "https://json.schemastore.org/tsconfig",
"extends": "astro/tsconfigs/strictest",
"include": [
".astro/types.d.ts",
"@types/**/*.d.ts",
"scripts/**/*.ts",
"api/**/*.ts",
"src/**/*.ts",
"src/**/*.tsx",
"src/**/*.astro",
"test/**/*.ts",
"test/**/*.tsx",
".github/actions/**/*.ts",
"*.ts"
],
"exclude": ["dist", ".vercel", "node_modules"],
"compilerOptions": {
/** Allow JavaScript files to be imported inside the project */
"allowJs": true,
/** Allow using default import syntax instead of `import * as MyModule` syntax */
"allowSyntheticDefaultImports": true,
/** Parse in strict mode and emit "use strict" for each source file. */
"alwaysStrict": true,
/** Report errors in JavaScript files. */
"checkJs": true,
/** Include a shim to ensure compatibility between ESM and CJS in the emitted JavaScript */
"esModuleInterop": true,
/**
* Force case sensitivity for file names on all file systems instead of using the
* file system's rules
*/
"forceConsistentCasingInFileNames": true,
/**
* Import helper functions from `tslib` once per project instead of
* inlining them per-file. Requires installing `tslib` as a dependency.
*/
"importHelpers": true,
/**
* Warn on code that can not be correctly interpreted by a single-file transpilation
* process like Babel
*/
"isolatedModules": false,
/** Type declaration files to include. */
//"lib": ["DOM", "ESNext", "WebWorker"],
/** Module code to generate as output. */
//"module": "ESNext",
/** Specify what JSX code is generated. */
"jsx": "react-jsx",
/** Specify the JSX factory function to use. */
"jsxImportSource": "preact",
/** Type declaration files to include. */
"lib": ["DOM", "ESNext", "WebWorker"],
/** Include React types for JSX namespace */
"types": ["react", "dom-speech-recognition"],
/** Module code to generate as output. */
"module": "ESNext",
/**
* 'node' for Node.js CommonJS implementation, 'node12' or 'nodenext' for Node.js
*/
"moduleResolution": "Bundler",
/** Unix EOL */
"newLine": "lf",
/** Do not truncate error messages. */
"noErrorTruncation": true,
/** Report errors for fallthrough cases in switch statement. */
"noFallthroughCasesInSwitch": true,
/** Ensure overriding members in derived classes are marked with an 'override' modifier. */
"noImplicitOverride": true,
/** Report error when not all code paths in function return a value. */
"noImplicitReturns": true,
/** Require undeclared properties from index signatures to use element accesses. */
"noPropertyAccessFromIndexSignature": true,
/** Include 'undefined' in index signature results */
"noUncheckedIndexedAccess": true,
/** Report errors on unused locals. */
"noUnusedLocals": true,
/** Report errors on unused parameters. */
"noUnusedParameters": true,
/** Import aliases */
"paths": {
"@actions/*": ["./src/actions/*"],
"@assets/*": ["./src/assets/*"],
"@cache/*": ["./.cache/*"],
"@components/*": ["./src/components/*"],
"@content/*": ["./src/content/*"],
"@data/*": ["./src/data/*"],
"@icons/*": ["./src/icons/*"],
"@integrations/*": ["./src/integrations/*"],
"@layouts/*": ["./src/layouts/*"],
"@lib/*": ["./src/lib/*"],
"@pages/*": ["./src/pages/*"],
"@styles/*": ["./src/styles/*"],
"@test/*": ["./test/*"],
"astro-vtbot": ["./@types/astro-vtbot"],
"@semantic-ui/astro-lit": ["./@types/semantic-ui__astro-lit/index.d.ts"],
"gsap/utils/VelocityTracker": ["./@types/gsap/velocity-tracker.d.ts"],
"gsap/utils/VelocityTracker.js": ["./@types/gsap/velocity-tracker.d.ts"]
},
/** Strip all comments from TypeScript files when converting into JavaScript */
"removeComments": true,
/**
* Using Node >=17.1 or LTS with `--experimental-json-modules` flag enabled
*/
"resolveJsonModule": true,
/**
* Skip type checking of all declaration files in `node_modules`, only doing so on explicit imports.
*/
"skipLibCheck": true,
/** Generate source maps */
"sourceMap": true,
/**
* Enable all of the strict mode family options: `alwaysStrict`, `strictNullChecks`,
* `strictBindCallApply`, `strictFunctionTypes`, `strictPropertyInitialization`,
* `noImplicitAny`, `noImplicitThis`, and `useUnknownInCatchVariables`.
*/
"strict": true,
/**
* Changes which JS features are downleveled and which are left intact. Choosing
* an unnecessarily low target will cause the bundle size to bloat with polyfills.
* Webhint will read this and `browserslist` in `package.json`, and give warnings
if they get out of sync.
*/
"target": "ESNext",
/**
* Specify a list of roots whose contents are expected to merge at run-time
* https://github.com/microsoft/TypeScript/issues/22217#issuecomment-370019383
* https://www.typescriptlang.org/docs/handbook/module-resolution.html#path-mapping
* This avoids needing for ts-node to include a top-level key of: "ts-node": { "files": true }
*/
"typeRoots": ["./@types", "./node_modules/@types"],
/** switches to the upcoming ECMA runtime behavior instead of TypeScript's legacy behavior. */
"useDefineForClassFields": true,
/**
* Do not transform or elide any imports or exports not marked as type-only, ensuring they
* are written in the output file's format based on the 'module' setting.
*
* DISABLED: This setting forces .js extensions in imports even for .ts files,
* which is confusing and makes the code less maintainable.
*/
"verbatimModuleSyntax": false
}
}