1 | declare namespace TsConfigJson {
|
2 | namespace CompilerOptions {
|
3 | export type JSX =
|
4 | | 'preserve'
|
5 | | 'react'
|
6 | | 'react-jsx'
|
7 | | 'react-jsxdev'
|
8 | | 'react-native';
|
9 |
|
10 | export type Module =
|
11 | | 'CommonJS'
|
12 | | 'AMD'
|
13 | | 'System'
|
14 | | 'UMD'
|
15 | | 'ES6'
|
16 | | 'ES2015'
|
17 | | 'ES2020'
|
18 | | 'ES2022'
|
19 | | 'ESNext'
|
20 | | 'Node16'
|
21 | | 'NodeNext'
|
22 | | 'Preserve'
|
23 | | 'None'
|
24 |
|
25 | | 'commonjs'
|
26 | | 'amd'
|
27 | | 'system'
|
28 | | 'umd'
|
29 | | 'es6'
|
30 | | 'es2015'
|
31 | | 'es2020'
|
32 | | 'es2022'
|
33 | | 'esnext'
|
34 | | 'node16'
|
35 | | 'nodenext'
|
36 | | 'preserve'
|
37 | | 'none';
|
38 |
|
39 | export type NewLine =
|
40 | | 'CRLF'
|
41 | | 'LF'
|
42 |
|
43 | | 'crlf'
|
44 | | 'lf';
|
45 |
|
46 | export type Target =
|
47 | | 'ES3'
|
48 | | 'ES5'
|
49 | | 'ES6'
|
50 | | 'ES2015'
|
51 | | 'ES2016'
|
52 | | 'ES2017'
|
53 | | 'ES2018'
|
54 | | 'ES2019'
|
55 | | 'ES2020'
|
56 | | 'ES2021'
|
57 | | 'ES2022'
|
58 | | 'ES2023'
|
59 | | 'ES2024'
|
60 | | 'ESNext'
|
61 |
|
62 | | 'es3'
|
63 | | 'es5'
|
64 | | 'es6'
|
65 | | 'es2015'
|
66 | | 'es2016'
|
67 | | 'es2017'
|
68 | | 'es2018'
|
69 | | 'es2019'
|
70 | | 'es2020'
|
71 | | 'es2021'
|
72 | | 'es2022'
|
73 | | 'es2023'
|
74 | | 'es2024'
|
75 | | 'esnext';
|
76 |
|
77 |
|
78 | export type Lib =
|
79 | | 'ES5'
|
80 | | 'ES6'
|
81 | | 'ES7'
|
82 | | 'ES2015'
|
83 | | 'ES2015.Collection'
|
84 | | 'ES2015.Core'
|
85 | | 'ES2015.Generator'
|
86 | | 'ES2015.Iterable'
|
87 | | 'ES2015.Promise'
|
88 | | 'ES2015.Proxy'
|
89 | | 'ES2015.Reflect'
|
90 | | 'ES2015.Symbol.WellKnown'
|
91 | | 'ES2015.Symbol'
|
92 | | 'ES2016'
|
93 | | 'ES2016.Array.Include'
|
94 | | 'ES2017'
|
95 | | 'ES2017.ArrayBuffer'
|
96 | | 'ES2017.Date'
|
97 | | 'ES2017.Intl'
|
98 | | 'ES2017.Object'
|
99 | | 'ES2017.SharedMemory'
|
100 | | 'ES2017.String'
|
101 | | 'ES2017.TypedArrays'
|
102 | | 'ES2018'
|
103 | | 'ES2018.AsyncGenerator'
|
104 | | 'ES2018.AsyncIterable'
|
105 | | 'ES2018.Intl'
|
106 | | 'ES2018.Promise'
|
107 | | 'ES2018.Regexp'
|
108 | | 'ES2019'
|
109 | | 'ES2019.Array'
|
110 | | 'ES2019.Object'
|
111 | | 'ES2019.String'
|
112 | | 'ES2019.Symbol'
|
113 | | 'ES2020'
|
114 | | 'ES2020.BigInt'
|
115 | | 'ES2020.Promise'
|
116 | | 'ES2020.String'
|
117 | | 'ES2020.Symbol.WellKnown'
|
118 | | 'ES2020.SharedMemory'
|
119 | | 'ES2020.Intl'
|
120 | | 'ES2021'
|
121 | | 'ES2021.Intl'
|
122 | | 'ES2021.Promise'
|
123 | | 'ES2021.String'
|
124 | | 'ES2021.WeakRef'
|
125 | | 'ES2022'
|
126 | | 'ES2022.Array'
|
127 | | 'ES2022.Error'
|
128 | | 'ES2022.Intl'
|
129 | | 'ES2022.Object'
|
130 | | 'ES2022.RegExp'
|
131 | | 'ES2022.String'
|
132 | | 'ES2023'
|
133 | | 'ES2023.Array'
|
134 | | 'ES2023.Collection'
|
135 | | 'ES2023.Intl'
|
136 | | 'ES2024'
|
137 | | 'ES2024.ArrayBuffer'
|
138 | | 'ES2024.Collection'
|
139 | | 'ES2024.Object'
|
140 | | 'ES2024.Promise'
|
141 | | 'ES2024.Regexp'
|
142 | | 'ES2024.SharedMemory'
|
143 | | 'ES2024.String'
|
144 | | 'ESNext'
|
145 | | 'ESNext.Array'
|
146 | | 'ESNext.AsyncIterable'
|
147 | | 'ESNext.BigInt'
|
148 | | 'ESNext.Collection'
|
149 | | 'ESNext.Decorators'
|
150 | | 'ESNext.Disposable'
|
151 | | 'ESNext.Intl'
|
152 | | 'ESNext.Iterator'
|
153 | | 'ESNext.Promise'
|
154 | | 'ESNext.String'
|
155 | | 'ESNext.Symbol'
|
156 | | 'ESNext.WeakRef'
|
157 | | 'DOM'
|
158 | | 'DOM.Iterable'
|
159 | | 'ScriptHost'
|
160 | | 'WebWorker'
|
161 | | 'WebWorker.AsyncIterable'
|
162 | | 'WebWorker.ImportScripts'
|
163 | | 'WebWorker.Iterable'
|
164 |
|
165 | | 'es5'
|
166 | | 'es6'
|
167 | | 'es7'
|
168 | | 'es2015'
|
169 | | 'es2015.collection'
|
170 | | 'es2015.core'
|
171 | | 'es2015.generator'
|
172 | | 'es2015.iterable'
|
173 | | 'es2015.promise'
|
174 | | 'es2015.proxy'
|
175 | | 'es2015.reflect'
|
176 | | 'es2015.symbol.wellknown'
|
177 | | 'es2015.symbol'
|
178 | | 'es2016'
|
179 | | 'es2016.array.include'
|
180 | | 'es2017'
|
181 | | 'es2017.arraybuffer'
|
182 | | 'es2017.date'
|
183 | | 'es2017.intl'
|
184 | | 'es2017.object'
|
185 | | 'es2017.sharedmemory'
|
186 | | 'es2017.string'
|
187 | | 'es2017.typedarrays'
|
188 | | 'es2018'
|
189 | | 'es2018.asyncgenerator'
|
190 | | 'es2018.asynciterable'
|
191 | | 'es2018.intl'
|
192 | | 'es2018.promise'
|
193 | | 'es2018.regexp'
|
194 | | 'es2019'
|
195 | | 'es2019.array'
|
196 | | 'es2019.object'
|
197 | | 'es2019.string'
|
198 | | 'es2019.symbol'
|
199 | | 'es2020'
|
200 | | 'es2020.bigint'
|
201 | | 'es2020.promise'
|
202 | | 'es2020.string'
|
203 | | 'es2020.symbol.wellknown'
|
204 | | 'es2020.sharedmemory'
|
205 | | 'es2020.intl'
|
206 | | 'es2021'
|
207 | | 'es2021.intl'
|
208 | | 'es2021.promise'
|
209 | | 'es2021.string'
|
210 | | 'es2021.weakref'
|
211 | | 'es2022'
|
212 | | 'es2022.array'
|
213 | | 'es2022.error'
|
214 | | 'es2022.intl'
|
215 | | 'es2022.object'
|
216 | | 'es2022.regexp'
|
217 | | 'es2022.string'
|
218 | | 'es2023'
|
219 | | 'es2023.array'
|
220 | | 'es2023.collection'
|
221 | | 'es2023.intl'
|
222 | | 'es2024'
|
223 | | 'es2024.arraybuffer'
|
224 | | 'es2024.collection'
|
225 | | 'es2024.object'
|
226 | | 'es2024.promise'
|
227 | | 'es2024.regexp'
|
228 | | 'es2024.sharedmemory'
|
229 | | 'es2024.string'
|
230 | | 'esnext'
|
231 | | 'esnext.array'
|
232 | | 'esnext.asynciterable'
|
233 | | 'esnext.bigint'
|
234 | | 'esnext.collection'
|
235 | | 'esnext.decorators'
|
236 | | 'esnext.disposable'
|
237 | | 'esnext.intl'
|
238 | | 'esnext.iterator'
|
239 | | 'esnext.promise'
|
240 | | 'esnext.string'
|
241 | | 'esnext.symbol'
|
242 | | 'esnext.weakref'
|
243 | | 'dom'
|
244 | | 'dom.iterable'
|
245 | | 'scripthost'
|
246 | | 'webworker'
|
247 | | 'webworker.asynciterable'
|
248 | | 'webworker.importscripts'
|
249 | | 'webworker.iterable';
|
250 |
|
251 | export type Plugin = {
|
252 | |
253 |
|
254 |
|
255 | name: string;
|
256 | };
|
257 |
|
258 | export type ImportsNotUsedAsValues =
|
259 | | 'remove'
|
260 | | 'preserve'
|
261 | | 'error';
|
262 |
|
263 | export type FallbackPolling =
|
264 | | 'fixedPollingInterval'
|
265 | | 'priorityPollingInterval'
|
266 | | 'dynamicPriorityPolling'
|
267 | | 'fixedInterval'
|
268 | | 'priorityInterval'
|
269 | | 'dynamicPriority'
|
270 | | 'fixedChunkSize';
|
271 |
|
272 | export type WatchDirectory =
|
273 | | 'useFsEvents'
|
274 | | 'fixedPollingInterval'
|
275 | | 'dynamicPriorityPolling'
|
276 | | 'fixedChunkSizePolling';
|
277 |
|
278 | export type WatchFile =
|
279 | | 'fixedPollingInterval'
|
280 | | 'priorityPollingInterval'
|
281 | | 'dynamicPriorityPolling'
|
282 | | 'useFsEvents'
|
283 | | 'useFsEventsOnParentDirectory'
|
284 | | 'fixedChunkSizePolling';
|
285 |
|
286 | export type ModuleResolution =
|
287 | | 'classic'
|
288 | | 'node'
|
289 | | 'node10'
|
290 | | 'node16'
|
291 | | 'nodenext'
|
292 | | 'bundler'
|
293 |
|
294 | | 'Classic'
|
295 | | 'Node'
|
296 | | 'Node10'
|
297 | | 'Node16'
|
298 | | 'NodeNext'
|
299 | | 'Bundler';
|
300 |
|
301 | export type ModuleDetection =
|
302 | | 'auto'
|
303 | | 'legacy'
|
304 | | 'force';
|
305 |
|
306 | export type IgnoreDeprecations = '5.0';
|
307 | }
|
308 |
|
309 | export type CompilerOptions = {
|
310 | |
311 |
|
312 |
|
313 |
|
314 |
|
315 |
|
316 | charset?: string;
|
317 |
|
318 | |
319 |
|
320 |
|
321 |
|
322 |
|
323 | composite?: boolean;
|
324 |
|
325 | |
326 |
|
327 |
|
328 |
|
329 |
|
330 | declaration?: boolean;
|
331 |
|
332 | |
333 |
|
334 |
|
335 | declarationDir?: string;
|
336 |
|
337 | |
338 |
|
339 |
|
340 |
|
341 |
|
342 | diagnostics?: boolean;
|
343 |
|
344 | |
345 |
|
346 |
|
347 |
|
348 |
|
349 | disableReferencedProjectLoad?: boolean;
|
350 |
|
351 | |
352 |
|
353 |
|
354 |
|
355 |
|
356 | noPropertyAccessFromIndexSignature?: boolean;
|
357 |
|
358 | |
359 |
|
360 |
|
361 |
|
362 |
|
363 | emitBOM?: boolean;
|
364 |
|
365 | |
366 |
|
367 |
|
368 |
|
369 |
|
370 | emitDeclarationOnly?: boolean;
|
371 |
|
372 | |
373 |
|
374 |
|
375 |
|
376 |
|
377 | exactOptionalPropertyTypes?: boolean;
|
378 |
|
379 | |
380 |
|
381 |
|
382 |
|
383 |
|
384 | incremental?: boolean;
|
385 |
|
386 | |
387 |
|
388 |
|
389 |
|
390 |
|
391 | tsBuildInfoFile?: string;
|
392 |
|
393 | |
394 |
|
395 |
|
396 |
|
397 |
|
398 | inlineSourceMap?: boolean;
|
399 |
|
400 | |
401 |
|
402 |
|
403 |
|
404 |
|
405 |
|
406 |
|
407 | inlineSources?: boolean;
|
408 |
|
409 | |
410 |
|
411 |
|
412 |
|
413 |
|
414 | jsx?: CompilerOptions.JSX;
|
415 |
|
416 | |
417 |
|
418 |
|
419 |
|
420 |
|
421 | reactNamespace?: string;
|
422 |
|
423 | |
424 |
|
425 |
|
426 |
|
427 |
|
428 | jsxFactory?: string;
|
429 |
|
430 | |
431 |
|
432 |
|
433 |
|
434 |
|
435 | jsxFragmentFactory?: string;
|
436 |
|
437 | |
438 |
|
439 |
|
440 |
|
441 |
|
442 | jsxImportSource?: string;
|
443 |
|
444 | |
445 |
|
446 |
|
447 |
|
448 |
|
449 | listFiles?: boolean;
|
450 |
|
451 | |
452 |
|
453 |
|
454 | mapRoot?: string;
|
455 |
|
456 | |
457 |
|
458 |
|
459 |
|
460 |
|
461 | module?: CompilerOptions.Module;
|
462 |
|
463 | /**
|
464 | Specifies module resolution strategy: 'node' (Node) or 'classic' (TypeScript pre 1.6).
|
465 |
|
466 | @default ['AMD', 'System', 'ES6'].includes(module) ? 'classic' : 'node'
|
467 | */
|
468 | moduleResolution?: CompilerOptions.ModuleResolution;
|
469 |
|
470 | /**
|
471 | Specifies the end of line sequence to be used when emitting files: 'crlf' (Windows) or 'lf' (Unix).
|
472 |
|
473 | @default 'LF'
|
474 | */
|
475 | newLine?: CompilerOptions.NewLine;
|
476 |
|
477 | /**
|
478 | Disable full type checking (only critical parse and emit errors will be reported).
|
479 |
|
480 | @default false
|
481 | */
|
482 | noCheck?: boolean;
|
483 |
|
484 | /**
|
485 | Do not emit output.
|
486 |
|
487 | @default false
|
488 | */
|
489 | noEmit?: boolean;
|
490 |
|
491 | /**
|
492 | Do not generate custom helper functions like `__extends` in compiled output.
|
493 |
|
494 | @default false
|
495 | */
|
496 | noEmitHelpers?: boolean;
|
497 |
|
498 | /**
|
499 | Do not emit outputs if any type checking errors were reported.
|
500 |
|
501 | @default false
|
502 | */
|
503 | noEmitOnError?: boolean;
|
504 |
|
505 | /**
|
506 | Warn on expressions and declarations with an implied 'any' type.
|
507 |
|
508 | @default false
|
509 | */
|
510 | noImplicitAny?: boolean;
|
511 |
|
512 | /**
|
513 | Raise error on 'this' expressions with an implied any type.
|
514 |
|
515 | @default false
|
516 | */
|
517 | noImplicitThis?: boolean;
|
518 |
|
519 | /**
|
520 | Report errors on unused locals.
|
521 |
|
522 | @default false
|
523 | */
|
524 | noUnusedLocals?: boolean;
|
525 |
|
526 | /**
|
527 | Report errors on unused parameters.
|
528 |
|
529 | @default false
|
530 | */
|
531 | noUnusedParameters?: boolean;
|
532 |
|
533 | /**
|
534 | Do not include the default library file (lib.d.ts).
|
535 |
|
536 | @default false
|
537 | */
|
538 | noLib?: boolean;
|
539 |
|
540 | /**
|
541 | Do not add triple-slash references or module import targets to the list of compiled files.
|
542 |
|
543 | @default false
|
544 | */
|
545 | noResolve?: boolean;
|
546 |
|
547 | /**
|
548 | Disable strict checking of generic signatures in function types.
|
549 |
|
550 | @default false
|
551 | @deprecated This option will be removed in TypeScript 5.5.
|
552 | */
|
553 | noStrictGenericChecks?: boolean;
|
554 |
|
555 | /**
|
556 | @deprecated use `skipLibCheck` instead.
|
557 | */
|
558 | skipDefaultLibCheck?: boolean;
|
559 |
|
560 | /**
|
561 | Skip type checking of declaration files.
|
562 |
|
563 | @default false
|
564 | */
|
565 | skipLibCheck?: boolean;
|
566 |
|
567 | /**
|
568 | Concatenate and emit output to single file.
|
569 | */
|
570 | outFile?: string;
|
571 |
|
572 | /**
|
573 | Redirect output structure to the directory.
|
574 | */
|
575 | outDir?: string;
|
576 |
|
577 | /**
|
578 | Do not erase const enum declarations in generated code.
|
579 |
|
580 | @default false
|
581 | */
|
582 | preserveConstEnums?: boolean;
|
583 |
|
584 | /**
|
585 | Do not resolve symlinks to their real path; treat a symlinked file like a real one.
|
586 |
|
587 | @default false
|
588 | */
|
589 | preserveSymlinks?: boolean;
|
590 |
|
591 | /**
|
592 | Keep outdated console output in watch mode instead of clearing the screen.
|
593 |
|
594 | @default false
|
595 | */
|
596 | preserveWatchOutput?: boolean;
|
597 |
|
598 | /**
|
599 | Stylize errors and messages using color and context (experimental).
|
600 |
|
601 | @default true // Unless piping to another program or redirecting output to a file.
|
602 | */
|
603 | pretty?: boolean;
|
604 |
|
605 | /**
|
606 | Do not emit comments to output.
|
607 |
|
608 | @default false
|
609 | */
|
610 | removeComments?: boolean;
|
611 |
|
612 | /**
|
613 | Specifies the root directory of input files.
|
614 |
|
615 | Use to control the output directory structure with `--outDir`.
|
616 | */
|
617 | rootDir?: string;
|
618 |
|
619 | /**
|
620 | Unconditionally emit imports for unresolved files.
|
621 |
|
622 | @default false
|
623 | */
|
624 | isolatedModules?: boolean;
|
625 |
|
626 | /**
|
627 | Require sufficient annotation on exports so other tools can trivially generate declaration files.
|
628 |
|
629 | @default false
|
630 | */
|
631 | isolatedDeclarations?: boolean;
|
632 |
|
633 | /**
|
634 | Generates corresponding '.map' file.
|
635 |
|
636 | @default false
|
637 | */
|
638 | sourceMap?: boolean;
|
639 |
|
640 | /**
|
641 | Specifies the location where debugger should locate TypeScript files instead of source locations.
|
642 | */
|
643 | sourceRoot?: string;
|
644 |
|
645 | /**
|
646 | Suppress excess property checks for object literals.
|
647 |
|
648 | @default false
|
649 | @deprecated This option will be removed in TypeScript 5.5.
|
650 | */
|
651 | suppressExcessPropertyErrors?: boolean;
|
652 |
|
653 | /**
|
654 | Suppress noImplicitAny errors for indexing objects lacking index signatures.
|
655 |
|
656 | @default false
|
657 | @deprecated This option will be removed in TypeScript 5.5.
|
658 | */
|
659 | suppressImplicitAnyIndexErrors?: boolean;
|
660 |
|
661 | /**
|
662 | Do not emit declarations for code that has an `@internal` annotation.
|
663 | */
|
664 | stripInternal?: boolean;
|
665 |
|
666 | /**
|
667 | Specify ECMAScript target version.
|
668 |
|
669 | @default 'es3'
|
670 | */
|
671 | target?: CompilerOptions.Target;
|
672 |
|
673 | /**
|
674 | Default catch clause variables as `unknown` instead of `any`.
|
675 |
|
676 | @default false
|
677 | */
|
678 | useUnknownInCatchVariables?: boolean;
|
679 |
|
680 | /**
|
681 | Watch input files.
|
682 |
|
683 | @default false
|
684 | @deprecated Use watchOptions instead.
|
685 | */
|
686 | watch?: boolean;
|
687 |
|
688 | /**
|
689 | Specify the polling strategy to use when the system runs out of or doesn't support native file watchers.
|
690 |
|
691 | @deprecated Use watchOptions.fallbackPolling instead.
|
692 | */
|
693 | fallbackPolling?: CompilerOptions.FallbackPolling;
|
694 |
|
695 | /**
|
696 | Specify the strategy for watching directories under systems that lack recursive file-watching functionality.
|
697 |
|
698 | @default 'useFsEvents'
|
699 | @deprecated Use watchOptions.watchDirectory instead.
|
700 | */
|
701 | watchDirectory?: CompilerOptions.WatchDirectory;
|
702 |
|
703 | /**
|
704 | Specify the strategy for watching individual files.
|
705 |
|
706 | @default 'useFsEvents'
|
707 | @deprecated Use watchOptions.watchFile instead.
|
708 | */
|
709 | watchFile?: CompilerOptions.WatchFile;
|
710 |
|
711 | /**
|
712 | Enables experimental support for ES7 decorators.
|
713 |
|
714 | @default false
|
715 | */
|
716 | experimentalDecorators?: boolean;
|
717 |
|
718 | /**
|
719 | Emit design-type metadata for decorated declarations in source.
|
720 |
|
721 | @default false
|
722 | */
|
723 | emitDecoratorMetadata?: boolean;
|
724 |
|
725 | /**
|
726 | Do not report errors on unused labels.
|
727 |
|
728 | @default false
|
729 | */
|
730 | allowUnusedLabels?: boolean;
|
731 |
|
732 | /**
|
733 | Report error when not all code paths in function return a value.
|
734 |
|
735 | @default false
|
736 | */
|
737 | noImplicitReturns?: boolean;
|
738 |
|
739 | /**
|
740 | Add `undefined` to a type when accessed using an index.
|
741 |
|
742 | @default false
|
743 | */
|
744 | noUncheckedIndexedAccess?: boolean;
|
745 |
|
746 | /**
|
747 | Report error if failed to find a source file for a side effect import.
|
748 |
|
749 | @default false
|
750 | */
|
751 | noUncheckedSideEffectImports?: boolean;
|
752 |
|
753 | /**
|
754 | Report errors for fallthrough cases in switch statement.
|
755 |
|
756 | @default false
|
757 | */
|
758 | noFallthroughCasesInSwitch?: boolean;
|
759 |
|
760 | /**
|
761 | Ensure overriding members in derived classes are marked with an override modifier.
|
762 |
|
763 | @default false
|
764 | */
|
765 | noImplicitOverride?: boolean;
|
766 |
|
767 | /**
|
768 | Do not report errors on unreachable code.
|
769 |
|
770 | @default false
|
771 | */
|
772 | allowUnreachableCode?: boolean;
|
773 |
|
774 | /**
|
775 | Disallow inconsistently-cased references to the same file.
|
776 |
|
777 | @default true
|
778 | */
|
779 | forceConsistentCasingInFileNames?: boolean;
|
780 |
|
781 | /**
|
782 | Emit a v8 CPU profile of the compiler run for debugging.
|
783 |
|
784 | @default 'profile.cpuprofile'
|
785 | */
|
786 | generateCpuProfile?: string;
|
787 |
|
788 | /**
|
789 | Generates an event trace and a list of types.
|
790 | */
|
791 | generateTrace?: boolean;
|
792 |
|
793 | /**
|
794 | Base directory to resolve non-relative module names.
|
795 | */
|
796 | baseUrl?: string;
|
797 |
|
798 | /**
|
799 | Specify path mapping to be computed relative to baseUrl option.
|
800 | */
|
801 | paths?: Record<string, string[]>;
|
802 |
|
803 | /**
|
804 | List of TypeScript language server plugins to load.
|
805 | */
|
806 | plugins?: CompilerOptions.Plugin[];
|
807 |
|
808 | /**
|
809 | Specify list of root directories to be used when resolving modules.
|
810 | */
|
811 | rootDirs?: string[];
|
812 |
|
813 | /**
|
814 | Specify list of directories for type definition files to be included.
|
815 | */
|
816 | typeRoots?: string[];
|
817 |
|
818 | /**
|
819 | Type declaration files to be included in compilation.
|
820 | */
|
821 | types?: string[];
|
822 |
|
823 | /**
|
824 | Enable tracing of the name resolution process.
|
825 |
|
826 | @default false
|
827 | */
|
828 | traceResolution?: boolean;
|
829 |
|
830 | /**
|
831 | Allow javascript files to be compiled.
|
832 |
|
833 | @default false
|
834 | */
|
835 | allowJs?: boolean;
|
836 |
|
837 | /**
|
838 | Do not truncate error messages.
|
839 |
|
840 | @default false
|
841 | */
|
842 | noErrorTruncation?: boolean;
|
843 |
|
844 | /**
|
845 | Allow default imports from modules with no default export. This does not affect code emit, just typechecking.
|
846 |
|
847 | @default module === 'system' || esModuleInterop
|
848 | */
|
849 | allowSyntheticDefaultImports?: boolean;
|
850 |
|
851 | /**
|
852 | Do not emit `'use strict'` directives in module output.
|
853 |
|
854 | @default false
|
855 | @deprecated This option will be removed in TypeScript 5.5.
|
856 | */
|
857 | noImplicitUseStrict?: boolean;
|
858 |
|
859 | /**
|
860 | Enable to list all emitted files.
|
861 |
|
862 | @default false
|
863 | */
|
864 | listEmittedFiles?: boolean;
|
865 |
|
866 | /**
|
867 | Disable size limit for JavaScript project.
|
868 |
|
869 | @default false
|
870 | */
|
871 | disableSizeLimit?: boolean;
|
872 |
|
873 | /**
|
874 | List of library files to be included in the compilation.
|
875 | */
|
876 | lib?: CompilerOptions.Lib[];
|
877 |
|
878 | /**
|
879 | Enable strict null checks.
|
880 |
|
881 | @default false
|
882 | */
|
883 | strictNullChecks?: boolean;
|
884 |
|
885 | /**
|
886 | The maximum dependency depth to search under `node_modules` and load JavaScript files. Only applicable with `--allowJs`.
|
887 |
|
888 | @default 0
|
889 | */
|
890 | maxNodeModuleJsDepth?: number;
|
891 |
|
892 | /**
|
893 | Import emit helpers (e.g. `__extends`, `__rest`, etc..) from tslib.
|
894 |
|
895 | @default false
|
896 | */
|
897 | importHelpers?: boolean;
|
898 |
|
899 | /**
|
900 | Specify emit/checking behavior for imports that are only used for types.
|
901 |
|
902 | @default 'remove'
|
903 | @deprecated Use `verbatimModuleSyntax` instead.
|
904 | */
|
905 | importsNotUsedAsValues?: CompilerOptions.ImportsNotUsedAsValues;
|
906 |
|
907 | /**
|
908 | Parse in strict mode and emit `'use strict'` for each source file.
|
909 |
|
910 | @default false
|
911 | */
|
912 | alwaysStrict?: boolean;
|
913 |
|
914 | /**
|
915 | Enable all strict type checking options.
|
916 |
|
917 | @default false
|
918 | */
|
919 | strict?: boolean;
|
920 |
|
921 | /**
|
922 | Enable stricter checking of of the `bind`, `call`, and `apply` methods on functions.
|
923 |
|
924 | @default false
|
925 | */
|
926 | strictBindCallApply?: boolean;
|
927 |
|
928 | /**
|
929 | Provide full support for iterables in `for-of`, spread, and destructuring when targeting `ES5` or `ES3`.
|
930 |
|
931 | @default false
|
932 | */
|
933 | downlevelIteration?: boolean;
|
934 |
|
935 | /**
|
936 | Report errors in `.js` files.
|
937 |
|
938 | @default false
|
939 | */
|
940 | checkJs?: boolean;
|
941 |
|
942 | /**
|
943 | Built-in iterators are instantiated with a `TReturn` type of undefined instead of `any`.
|
944 |
|
945 | @default false
|
946 | */
|
947 | strictBuiltinIteratorReturn?: boolean;
|
948 |
|
949 | /**
|
950 | Disable bivariant parameter checking for function types.
|
951 |
|
952 | @default false
|
953 | */
|
954 | strictFunctionTypes?: boolean;
|
955 |
|
956 | /**
|
957 | Ensure non-undefined class properties are initialized in the constructor.
|
958 |
|
959 | @default false
|
960 | */
|
961 | strictPropertyInitialization?: boolean;
|
962 |
|
963 | /**
|
964 | Emit `__importStar` and `__importDefault` helpers for runtime Babel ecosystem compatibility and enable `--allowSyntheticDefaultImports` for typesystem compatibility.
|
965 |
|
966 | @default false
|
967 | */
|
968 | esModuleInterop?: boolean;
|
969 |
|
970 | /**
|
971 | Allow accessing UMD globals from modules.
|
972 |
|
973 | @default false
|
974 | */
|
975 | allowUmdGlobalAccess?: boolean;
|
976 |
|
977 | /**
|
978 | Resolve `keyof` to string valued property names only (no numbers or symbols).
|
979 |
|
980 | @default false
|
981 | @deprecated This option will be removed in TypeScript 5.5.
|
982 | */
|
983 | keyofStringsOnly?: boolean;
|
984 |
|
985 | /**
|
986 | Emit ECMAScript standard class fields.
|
987 |
|
988 | @default false
|
989 | */
|
990 | useDefineForClassFields?: boolean;
|
991 |
|
992 | /**
|
993 | Generates a sourcemap for each corresponding `.d.ts` file.
|
994 |
|
995 | @default false
|
996 | */
|
997 | declarationMap?: boolean;
|
998 |
|
999 | /**
|
1000 | Include modules imported with `.json` extension.
|
1001 |
|
1002 | @default false
|
1003 | */
|
1004 | resolveJsonModule?: boolean;
|
1005 |
|
1006 | /**
|
1007 | Have recompiles in '--incremental' and '--watch' assume that changes within a file will only affect files directly depending on it.
|
1008 |
|
1009 | @default false
|
1010 | */
|
1011 | assumeChangesOnlyAffectDirectDependencies?: boolean;
|
1012 |
|
1013 | /**
|
1014 | Output more detailed compiler performance information after building.
|
1015 |
|
1016 | @default false
|
1017 | */
|
1018 | extendedDiagnostics?: boolean;
|
1019 |
|
1020 | /**
|
1021 | Print names of files that are part of the compilation and then stop processing.
|
1022 |
|
1023 | @default false
|
1024 | */
|
1025 | listFilesOnly?: boolean;
|
1026 |
|
1027 | /**
|
1028 | Disable preferring source files instead of declaration files when referencing composite projects.
|
1029 |
|
1030 | @default true if composite, false otherwise
|
1031 | */
|
1032 | disableSourceOfProjectReferenceRedirect?: boolean;
|
1033 |
|
1034 | /**
|
1035 | Opt a project out of multi-project reference checking when editing.
|
1036 |
|
1037 | @default false
|
1038 | */
|
1039 | disableSolutionSearching?: boolean;
|
1040 |
|
1041 | /**
|
1042 | Print names of files which TypeScript sees as a part of your project and the reason they are part of the compilation.
|
1043 |
|
1044 | @default false
|
1045 | */
|
1046 | explainFiles?: boolean;
|
1047 |
|
1048 | /**
|
1049 | Preserve unused imported values in the JavaScript output that would otherwise be removed.
|
1050 |
|
1051 | @default true
|
1052 | @deprecated Use `verbatimModuleSyntax` instead.
|
1053 | */
|
1054 | preserveValueImports?: boolean;
|
1055 |
|
1056 | /**
|
1057 | List of file name suffixes to search when resolving a module.
|
1058 | */
|
1059 | moduleSuffixes?: string[];
|
1060 |
|
1061 | /**
|
1062 | Control what method is used to detect module-format JS files.
|
1063 |
|
1064 | @default 'auto'
|
1065 | */
|
1066 | moduleDetection?: CompilerOptions.ModuleDetection;
|
1067 |
|
1068 | /**
|
1069 | Allows TypeScript files to import each other with a TypeScript-specific extension like .ts, .mts, or .tsx.
|
1070 |
|
1071 | @default false
|
1072 | */
|
1073 | allowImportingTsExtensions?: boolean;
|
1074 |
|
1075 | /**
|
1076 | Forces TypeScript to consult the exports field of package.json files if it ever reads from a package in node_modules.
|
1077 |
|
1078 | @default false
|
1079 | */
|
1080 | resolvePackageJsonExports?: boolean;
|
1081 |
|
1082 | /**
|
1083 | Forces TypeScript to consult the imports field of package.json files when performing a lookup that starts with # from a file whose ancestor directory contains a package.json.
|
1084 |
|
1085 | @default false
|
1086 | */
|
1087 | resolvePackageJsonImports?: boolean;
|
1088 |
|
1089 | /**
|
1090 | Suppress errors for file formats that TypeScript does not understand.
|
1091 |
|
1092 | @default false
|
1093 | */
|
1094 | allowArbitraryExtensions?: boolean;
|
1095 |
|
1096 | /**
|
1097 | List of additional conditions that should succeed when TypeScript resolves from package.json.
|
1098 | */
|
1099 | customConditions?: string[];
|
1100 |
|
1101 | /**
|
1102 | Anything that uses the type modifier is dropped entirely.
|
1103 |
|
1104 | @default false
|
1105 | */
|
1106 | verbatimModuleSyntax?: boolean;
|
1107 |
|
1108 | /**
|
1109 | Suppress deprecation warnings
|
1110 | */
|
1111 | ignoreDeprecations?: CompilerOptions.IgnoreDeprecations;
|
1112 | };
|
1113 |
|
1114 | namespace WatchOptions {
|
1115 | export type WatchFileKind =
|
1116 | | 'FixedPollingInterval'
|
1117 | | 'PriorityPollingInterval'
|
1118 | | 'DynamicPriorityPolling'
|
1119 | | 'FixedChunkSizePolling'
|
1120 | | 'UseFsEvents'
|
1121 | | 'UseFsEventsOnParentDirectory';
|
1122 |
|
1123 | export type WatchDirectoryKind =
|
1124 | | 'UseFsEvents'
|
1125 | | 'FixedPollingInterval'
|
1126 | | 'DynamicPriorityPolling'
|
1127 | | 'FixedChunkSizePolling';
|
1128 |
|
1129 | export type PollingWatchKind =
|
1130 | | 'FixedInterval'
|
1131 | | 'PriorityInterval'
|
1132 | | 'DynamicPriority'
|
1133 | | 'FixedChunkSize';
|
1134 | }
|
1135 |
|
1136 | export type WatchOptions = {
|
1137 |
|
1138 | |
1139 |
|
1140 |
|
1141 |
|
1142 |
|
1143 | watchFile?: WatchOptions.WatchFileKind | Lowercase<WatchOptions.WatchFileKind>;
|
1144 |
|
1145 | |
1146 |
|
1147 |
|
1148 |
|
1149 |
|
1150 | watchDirectory?: WatchOptions.WatchDirectoryKind | Lowercase<WatchOptions.WatchDirectoryKind>;
|
1151 |
|
1152 | |
1153 |
|
1154 |
|
1155 | fallbackPolling?: WatchOptions.PollingWatchKind | Lowercase<WatchOptions.PollingWatchKind>;
|
1156 |
|
1157 | |
1158 |
|
1159 |
|
1160 | synchronousWatchDirectory?: boolean;
|
1161 |
|
1162 | |
1163 |
|
1164 |
|
1165 | excludeDirectories?: string[];
|
1166 |
|
1167 | |
1168 |
|
1169 |
|
1170 | excludeFiles?: string[];
|
1171 | };
|
1172 |
|
1173 | |
1174 |
|
1175 |
|
1176 | export type TypeAcquisition = {
|
1177 | |
1178 |
|
1179 |
|
1180 | enable?: boolean;
|
1181 |
|
1182 | |
1183 |
|
1184 |
|
1185 | include?: string[];
|
1186 |
|
1187 | |
1188 |
|
1189 |
|
1190 | exclude?: string[];
|
1191 |
|
1192 | |
1193 |
|
1194 |
|
1195 | disableFilenameBasedTypeAcquisition?: boolean;
|
1196 | };
|
1197 |
|
1198 | export type References = {
|
1199 | |
1200 |
|
1201 |
|
1202 | path: string;
|
1203 |
|
1204 | |
1205 |
|
1206 |
|
1207 | originalPath?: string;
|
1208 |
|
1209 | |
1210 |
|
1211 |
|
1212 |
|
1213 |
|
1214 |
|
1215 | prepend?: boolean;
|
1216 |
|
1217 | |
1218 |
|
1219 |
|
1220 | circular?: boolean;
|
1221 | };
|
1222 | }
|
1223 |
|
1224 |
|
1225 |
|
1226 |
|
1227 |
|
1228 |
|
1229 | export type TsConfigJson = {
|
1230 | |
1231 |
|
1232 |
|
1233 | compilerOptions?: TsConfigJson.CompilerOptions;
|
1234 |
|
1235 | |
1236 |
|
1237 |
|
1238 | watchOptions?: TsConfigJson.WatchOptions;
|
1239 |
|
1240 | |
1241 |
|
1242 |
|
1243 | typeAcquisition?: TsConfigJson.TypeAcquisition;
|
1244 |
|
1245 | |
1246 |
|
1247 |
|
1248 | compileOnSave?: boolean;
|
1249 |
|
1250 | |
1251 |
|
1252 |
|
1253 | extends?: string | string[];
|
1254 |
|
1255 | |
1256 |
|
1257 |
|
1258 | files?: string[];
|
1259 |
|
1260 | |
1261 |
|
1262 |
|
1263 |
|
1264 |
|
1265 | exclude?: string[];
|
1266 |
|
1267 | |
1268 |
|
1269 |
|
1270 |
|
1271 |
|
1272 | include?: string[];
|
1273 |
|
1274 | |
1275 |
|
1276 |
|
1277 | references?: TsConfigJson.References[];
|
1278 | };
|