2022-08-06 00:06:18 -04:00
|
|
|
{
|
2022-08-25 16:15:27 -03:00
|
|
|
"$schema": "https://json.schemastore.org/tsconfig",
|
2022-08-06 00:06:18 -04:00
|
|
|
"compilerOptions": {
|
|
|
|
// Enable top-level await, and other modern ESM features.
|
|
|
|
"target": "ESNext",
|
|
|
|
"module": "ESNext",
|
2023-11-09 18:07:49 +01:00
|
|
|
// Enable module resolution without file extensions on relative paths, for things like npm package imports.
|
2023-07-26 15:13:22 +02:00
|
|
|
"moduleResolution": "Bundler",
|
|
|
|
// Allow importing TypeScript files using their native extension (.ts(x)).
|
|
|
|
"allowImportingTsExtensions": true,
|
2022-08-06 00:06:18 -04:00
|
|
|
// Enable JSON imports.
|
|
|
|
"resolveJsonModule": true,
|
2023-07-26 15:13:22 +02:00
|
|
|
// Enforce the usage of type-only imports when needed, which helps avoiding bundling issues.
|
|
|
|
"verbatimModuleSyntax": true,
|
|
|
|
// Ensure that each file can be transpiled without relying on other imports.
|
|
|
|
// This is redundant with the previous option, however it ensures that it's on even if someone disable `verbatimModuleSyntax`
|
2022-08-06 00:06:18 -04:00
|
|
|
"isolatedModules": true,
|
2022-08-25 16:15:27 -03:00
|
|
|
// Astro directly run TypeScript code, no transpilation needed.
|
2022-08-06 00:06:18 -04:00
|
|
|
"noEmit": true,
|
2023-07-26 15:13:22 +02:00
|
|
|
// Report an error when importing a file using a casing different from another import of the same file.
|
2022-08-25 16:15:27 -03:00
|
|
|
"forceConsistentCasingInFileNames": true,
|
|
|
|
// Properly support importing CJS modules in ESM
|
2023-01-17 09:43:07 +08:00
|
|
|
"esModuleInterop": true,
|
|
|
|
// Skip typechecking libraries and .d.ts files
|
2023-03-07 16:12:21 +01:00
|
|
|
"skipLibCheck": true,
|
2023-06-05 17:31:21 +02:00
|
|
|
// Allow JavaScript files to be imported
|
|
|
|
"allowJs": true
|
2022-08-06 00:06:18 -04:00
|
|
|
}
|
|
|
|
}
|