diff --git a/packages/app/tsconfig.json b/packages/app/tsconfig.json index a96c821699ab..347deb1bb0be 100644 --- a/packages/app/tsconfig.json +++ b/packages/app/tsconfig.json @@ -13,7 +13,6 @@ ], "compilerOptions": { "noImplicitThis": true, - "useDefineForClassFields": true, "paths": { "@cy/i18n": ["../frontend-shared/src/locales/i18n"], "@cy/components/*": ["../frontend-shared/src/components/*"], @@ -21,7 +20,6 @@ "@cy/store/*": ["../frontend-shared/src/store/*"], "@packages/*": ["../*"] }, - "allowJs": true, "types": [ "cypress", "cypress-real-events", diff --git a/packages/config/tsconfig.json b/packages/config/tsconfig.json index 06872625a5ba..cf4b494620ff 100644 --- a/packages/config/tsconfig.json +++ b/packages/config/tsconfig.json @@ -7,19 +7,9 @@ "test" ], "compilerOptions": { - "strict": true, "allowJs": false, "rootDir": "src", "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": ["node"], "typeRoots": [ "../../node_modules/@types" diff --git a/packages/data-context/tsconfig.json b/packages/data-context/tsconfig.json index 69d4331d9027..587382a7499e 100644 --- a/packages/data-context/tsconfig.json +++ b/packages/data-context/tsconfig.json @@ -9,19 +9,8 @@ ], "compilerOptions": { "lib": ["esnext"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUnusedLocals": false, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": ["cypress"], } } \ No newline at end of file diff --git a/packages/driver/tsconfig.json b/packages/driver/tsconfig.json index b22d122add99..33203e370049 100644 --- a/packages/driver/tsconfig.json +++ b/packages/driver/tsconfig.json @@ -3,23 +3,15 @@ "compilerOptions": { "target": "ES2016", "lib": ["ES2021", "DOM", "DOM.Iterable"], - "module": "commonjs", "allowJs": true, - "noImplicitAny": false, "noImplicitThis": false, "strictFunctionTypes": true, "preserveWatchOutput": true, "sourceMap": true, - "importHelpers": true, "strictNullChecks": true, - "strict": true, "forceConsistentCasingInFileNames": true, - "skipLibCheck": true, "noEmit": true, - "noImplicitReturns": true, - "allowSyntheticDefaultImports": true, "outDir": "dist", - "esModuleInterop": true, "noErrorTruncation": true, "types": [] }, diff --git a/packages/errors/tsconfig.json b/packages/errors/tsconfig.json index e4d65fa86687..dfb951b17cde 100644 --- a/packages/errors/tsconfig.json +++ b/packages/errors/tsconfig.json @@ -4,18 +4,8 @@ "src", ], "compilerOptions": { - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, "noImplicitReturns": false, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", } } \ No newline at end of file diff --git a/packages/extension/tsconfig.json b/packages/extension/tsconfig.json index 2553bd5cab6e..aa782866197b 100644 --- a/packages/extension/tsconfig.json +++ b/packages/extension/tsconfig.json @@ -1,12 +1,7 @@ { + "extends": "../ts/tsconfig.json", "compilerOptions": { "target": "es2015", - "module": "commonjs", - "allowJs": true, - "allowSyntheticDefaultImports": true, - "esModuleInterop": true, - "noImplicitAny": false, - "importHelpers": true, "strict": false } } diff --git a/packages/frontend-shared/tsconfig.json b/packages/frontend-shared/tsconfig.json index 29b65c440301..4c289529abac 100644 --- a/packages/frontend-shared/tsconfig.json +++ b/packages/frontend-shared/tsconfig.json @@ -1,55 +1,12 @@ { + "extends": "../ts/tsconfig.json", "compilerOptions": { - /* Basic Options */ - "target": "ES2018", "module": "esnext", "lib": ["dom", "ESNext"], - /* - * Allow javascript files to be compiled. - * Override this in modules that need JS - */ - "noEmit": true, "jsx": "preserve", "preserveWatchOutput": true, - // "checkJs": true, /* Report errors in .js files. */ - // "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ - /* Generates corresponding '.d.ts' file. */ - // "declaration": true, - // "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ - /* Generates corresponding '.map' file. */ - "sourceMap": true, - /* Import emit helpers from 'tslib'. */ - "importHelpers": true, - "strictNullChecks": true, - // "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */ - // "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */ - /* Strict Type-Checking Options */ - // "traceResolution": true, - "strict": true, - "noImplicitAny": false, "noImplicitThis": false, - "forceConsistentCasingInFileNames": true, - /** - * Skip type checking of all declaration files (*.d.ts). - * TODO: Look into changing this in the future - */ - /* Additional Checks */ - "skipLibCheck": true, - /* Report errors on unused locals. */ - // "noEmit": true, - "noUnusedLocals": false, - // "noUnusedParameters": true, /* Report errors on unused parameters. */ - /* Report error when not all code paths in function return a value. */ - "noImplicitReturns": true, - // "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ - /* Module Resolution Options */ - "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ - // "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ - // "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ - // "rootDirs": ["../driver/src"], /* List of root folders whose combined content represents the structure of the project at runtime. */ - // "typeRoots": [] /* List of folders to include type definitions from. */ - - /* Type declaration files to be included in compilation. */ + "noErrorTruncation": true, "paths": { "@cy/i18n": ["../frontend-shared/src/locales/i18n"], "@cy/components/*": ["../frontend-shared/src/components/*"] @@ -63,17 +20,5 @@ "cypress-real-events", "cypress" ], - "allowSyntheticDefaultImports": true, - "esModuleInterop": true, - "noErrorTruncation": true, - "experimentalDecorators": true, - "resolveJsonModule": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", - "useUnknownInCatchVariables": false } } diff --git a/packages/graphql/src/utils/nexusTypegenUtils.ts b/packages/graphql/src/utils/nexusTypegenUtils.ts index bd8793b09e01..f209bc45af2e 100644 --- a/packages/graphql/src/utils/nexusTypegenUtils.ts +++ b/packages/graphql/src/utils/nexusTypegenUtils.ts @@ -92,7 +92,6 @@ const nexusTypegenDebounced = (cfg: NexusTypegenCfg) => { debounced[cfg.filePath] = debounced[cfg.filePath] ?? _.debounce(nexusTypegen, 500) - // @ts-expect-error debounced[cfg.filePath](cfg) } diff --git a/packages/graphql/tsconfig.json b/packages/graphql/tsconfig.json index 1b1ae93cc444..d7e45065be2f 100644 --- a/packages/graphql/tsconfig.json +++ b/packages/graphql/tsconfig.json @@ -10,19 +10,8 @@ ], "compilerOptions": { "lib": ["esnext"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "noUnusedLocals": false, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": [] }, } diff --git a/packages/icons/tsconfig.json b/packages/icons/tsconfig.json index 0c6beeacaeb6..8995f295a6c7 100644 --- a/packages/icons/tsconfig.json +++ b/packages/icons/tsconfig.json @@ -1,20 +1,8 @@ { "extends": "../ts/tsconfig.json", "compilerOptions": { - "strict": true, "allowJs": false, "noImplicitAny": true, - "noUnusedLocals": false, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "outDir": "dist", - "declaration": true }, } \ No newline at end of file diff --git a/packages/launcher/tsconfig.json b/packages/launcher/tsconfig.json index 22cbe18d5cb9..41c9480108b1 100644 --- a/packages/launcher/tsconfig.json +++ b/packages/launcher/tsconfig.json @@ -5,7 +5,6 @@ "./index.ts" ], "compilerOptions": { - "skipLibCheck": true }, "files": [ "./../ts/index.d.ts" diff --git a/packages/reporter/tsconfig.json b/packages/reporter/tsconfig.json index 99b6a70b5bf3..be6c7cd941b3 100644 --- a/packages/reporter/tsconfig.json +++ b/packages/reporter/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "../ts/tsconfig.json", "compilerOptions": { - "useDefineForClassFields": true, "types": [ "node", "cypress", diff --git a/packages/scaffold-config/tsconfig.json b/packages/scaffold-config/tsconfig.json index 935ec8b2ab6b..ae027f650086 100644 --- a/packages/scaffold-config/tsconfig.json +++ b/packages/scaffold-config/tsconfig.json @@ -10,19 +10,8 @@ ], "compilerOptions": { "lib": ["esnext"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUnusedLocals": false, - "noUncheckedIndexedAccess": true, - "ignoreDeprecations": "5.0", - /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", "types": [] } } \ No newline at end of file diff --git a/packages/server/lib/automation/util.ts b/packages/server/lib/automation/util.ts index bc3caab879d3..baf04a9ec320 100644 --- a/packages/server/lib/automation/util.ts +++ b/packages/server/lib/automation/util.ts @@ -1,6 +1,7 @@ import type playwright from 'playwright-webkit' import { domainMatch } from 'tough-cookie' +// @ts-ignore export type CyCookie = Pick & { // use `undefined` instead of `unspecified` sameSite?: 'no_restriction' | 'lax' | 'strict' @@ -8,6 +9,7 @@ export type CyCookie = Pick { diff --git a/packages/server/lib/modes/interactive.ts b/packages/server/lib/modes/interactive.ts index c58dfa2a3e82..bca0c83b11b4 100644 --- a/packages/server/lib/modes/interactive.ts +++ b/packages/server/lib/modes/interactive.ts @@ -125,6 +125,7 @@ export = { show: true, frame: true, transparent: false, + // @ts-ignore icon: image.createFromPath(cyIcons.getPathToIcon('icon_64x64.png')), }, } diff --git a/packages/server/tsconfig.json b/packages/server/tsconfig.json index 5a2415042012..9c69ae92c343 100644 --- a/packages/server/tsconfig.json +++ b/packages/server/tsconfig.json @@ -9,12 +9,5 @@ ], "compilerOptions": { "lib": ["esnext"], - "types": [ - "mocha", - "node" - ], - "resolveJsonModule": true, - "noUnusedLocals": false, - "importHelpers": true } } diff --git a/packages/socket/tsconfig.json b/packages/socket/tsconfig.json index 9b7d0907d5eb..94523723d342 100644 --- a/packages/socket/tsconfig.json +++ b/packages/socket/tsconfig.json @@ -1,7 +1,6 @@ { "extends": "./../ts/tsconfig.json", "compilerOptions": { - "strict": true, "noImplicitAny": true, "skipLibCheck": false }, diff --git a/packages/telemetry/tsconfig.json b/packages/telemetry/tsconfig.json index edd15e17bb40..d887c0486cc8 100644 --- a/packages/telemetry/tsconfig.json +++ b/packages/telemetry/tsconfig.json @@ -4,13 +4,8 @@ "compilerOptions": { "outDir": "./dist", "lib": ["esnext", "DOM"], - "strict": true, "allowJs": false, "noImplicitAny": true, - "resolveJsonModule": true, - "experimentalDecorators": true, - "noUnusedLocals": false, - "noUncheckedIndexedAccess": true, "types": ["cypress"], } } diff --git a/packages/ts/README.md b/packages/ts/README.md index dcf27567d4d7..4c46ce9e2384 100644 --- a/packages/ts/README.md +++ b/packages/ts/README.md @@ -1,6 +1,6 @@ # TS -Internal package used to standardize this repo's version of `ts-node` used for development. In production we pre-transpile all of the typescript so this packages `register` export is a no-op +Internal package used to standardize this repo's version of `ts-node` and the base `tsconfig` options used for development. In production we pre-transpile all of the typescript so this packages `register` export is a no-op ## Installing N/A - handled by the top level `yarn install` diff --git a/packages/ts/tsconfig.json b/packages/ts/tsconfig.json index 0f0e239b759a..20f39e2b453c 100644 --- a/packages/ts/tsconfig.json +++ b/packages/ts/tsconfig.json @@ -1,65 +1,118 @@ { "compilerOptions": { - /* Basic Options */ - "target": "ES2018", /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', or 'ESNEXT'. */ - "module": "commonjs", /* Specify module code generation: 'commonjs', 'amd', 'system', 'umd' or 'es2015'. */ - "lib": ["es2021"], /* Specify library files to be included in the compilation: */ - // "allowJs": true, /* Allow javascript files to be compiled. */ - // "checkJs": true, /* Report errors in .js files. */ - "jsx": "react", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ - "skipLibCheck": true, - // "declaration": true, /* Generates corresponding '.d.ts' file. */ - // "sourceMap": true, /* Generates corresponding '.map' file. */ - // "outFile": "./", /* Concatenate and emit output to single file. */ - // "outDir": "./", /* Redirect output structure to the directory. */ - // "rootDir": "./", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */ - // "removeComments": true, /* Do not emit comments to output. */ - // "noEmit": true, /* Do not emit outputs. */ - "importHelpers": true, /* Import emit helpers from 'tslib'. */ - // "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */ - // "isolatedModules": true, /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */ - "useUnknownInCatchVariables": false, + /* Visit https://aka.ms/tsconfig to read more about this file */ - /* Strict Type-Checking Options */ - "strict": true, /* Enable all strict type-checking options. */ - "noImplicitAny": false, /* Raise error on expressions and declarations with an implied 'any' type. */ - // "strictNullChecks": true, /* Enable strict null checks. */ - // "noImplicitThis": true, /* Raise error on 'this' expressions with an implied 'any' type. */ - // "alwaysStrict": true, /* Parse in strict mode and emit "use strict" for each source file. */ + /* Projects */ + // "incremental": true, /* Save .tsbuildinfo files to allow for incremental compilation of projects. */ + // "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */ + // "tsBuildInfoFile": "./.tsbuildinfo", /* Specify the path to .tsbuildinfo incremental compilation file. */ + // "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects. */ + // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */ + // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */ - /* Additional Checks */ - - // noUnusedLocals should be linted, not type-check'ed - "noUnusedLocals": false, /* Report errors on unused locals. */ - "noUnusedParameters": false, /* Report errors on unused parameters. */ - "noImplicitReturns": true, /* Report error when not all code paths in function return a value. */ - "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ + /* Language and Environment */ + "target": "ES2018", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */ + "lib": ["es2021"], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ + "jsx": "react", /* Specify what JSX code is generated. */ + "experimentalDecorators": true, /* Enable experimental support for legacy experimental decorators. */ + // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */ + // "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h'. */ + // "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */ + // "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using 'jsx: react-jsx*'. */ + // "reactNamespace": "", /* Specify the object invoked for 'createElement'. This only applies when targeting 'react' JSX emit. */ + // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */ + // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */ + // "moduleDetection": "auto", /* Control what method is used to detect module-format JS files. */ - /* Module Resolution Options */ - "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */ - // "baseUrl": "./", /* Base directory to resolve non-absolute module names. */ - // "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */ - // "rootDirs": [], /* List of root folders whose combined content represents the structure of the project at runtime. */ - //"typeRoots": [], /* List of folders to include type definitions from. */ - "types": ["mocha", "node"], /* Type declaration files to be included in compilation. */ - "allowSyntheticDefaultImports": true, /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */ - "esModuleInterop": true, + /* Modules */ + "module": "commonjs", /* Specify what module code is generated. */ + // "rootDir": "./", /* Specify the root folder within your source files. */ + "moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */ + // "baseUrl": "./", /* Specify the base directory to resolve non-relative module names. */ + // "paths": {}, /* Specify a set of entries that re-map imports to additional lookup locations. */ + // "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */ + // "typeRoots": [], /* Specify multiple folders that act like './node_modules/@types'. */ + "types": ["mocha", "node"], /* Specify type package names to be included without being referenced in a source file. */ + // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ + // "moduleSuffixes": [], /* List of file name suffixes to search when resolving a module. */ + // "allowImportingTsExtensions": true, /* Allow imports to include TypeScript file extensions. Requires '--moduleResolution bundler' and either '--noEmit' or '--emitDeclarationOnly' to be set. */ + // "resolvePackageJsonExports": true, /* Use the package.json 'exports' field when resolving package imports. */ + // "resolvePackageJsonImports": true, /* Use the package.json 'imports' field when resolving imports. */ + // "customConditions": [], /* Conditions to set in addition to the resolver-specific defaults when resolving imports. */ + "resolveJsonModule": true, /* Enable importing .json files. */ + // "allowArbitraryExtensions": true, /* Enable importing files with any extension, provided a declaration file is present. */ + // "noResolve": true, /* Disallow 'import's, 'require's or ''s from expanding the number of files TypeScript should add to a project. */ - /* Source Map Options */ - // "sourceRoot": "./", /* Specify the location where debugger should locate TypeScript files instead of source locations. */ - // "mapRoot": "./", /* Specify the location where debugger should locate map files instead of generated locations. */ - // "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */ - // "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ + /* JavaScript Support */ + // "allowJs": true, /* Allow JavaScript files to be a part of your program. Use the 'checkJS' option to get errors from these files. */ + // "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */ + // "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from 'node_modules'. Only applicable with 'allowJs'. */ - /* Experimental Options */ - "experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */ - // "emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */ - "ignoreDeprecations": "5.0", + /* Emit */ + // "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */ + // "declarationMap": true, /* Create sourcemaps for d.ts files. */ + // "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */ + // "sourceMap": true, /* Create source map files for emitted JavaScript files. */ + // "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */ + // "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If 'declaration' is true, also designates a file that bundles all .d.ts output. */ + // "outDir": "./", /* Specify an output folder for all emitted files. */ + // "removeComments": true, /* Disable emitting comments. */ + // "noEmit": true, /* Disable emitting files from a compilation. */ + "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */ + /* + * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior + * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. + */ + "importsNotUsedAsValues": "error", /* Specify emit/checking behavior for imports that are only used for types. */ + // "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */ + // "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */ + // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ + // "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */ + // "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */ + // "newLine": "crlf", /* Set the newline character for emitting files. */ + // "stripInternal": true, /* Disable emitting declarations that have '@internal' in their JSDoc comments. */ + // "noEmitHelpers": true, /* Disable generating custom helper functions like '__extends' in compiled output. */ + // "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */ + // "preserveConstEnums": true, /* Disable erasing 'const enum' declarations in generated code. */ + // "declarationDir": "./", /* Specify the output directory for generated declaration files. */ + // "preserveValueImports": true, /* Preserve unused imported values in the JavaScript output that would otherwise be removed. */ + + /* Interop Constraints */ + // "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */ + // "verbatimModuleSyntax": 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. */ + "allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */ + "esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */ + // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */ + "forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */ + + /* Type Checking */ + "strict": true, /* Enable all strict type-checking options. */ + "noImplicitAny": false, /* Enable error reporting for expressions and declarations with an implied 'any' type. */ + // "strictNullChecks": true, /* When type checking, take into account 'null' and 'undefined'. */ + // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */ + // "strictBindCallApply": true, /* Check that the arguments for 'bind', 'call', and 'apply' methods match the original function. */ + // "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */ + // "noImplicitThis": true, /* Enable error reporting when 'this' is given the type 'any'. */ + "useUnknownInCatchVariables": false, /* Default catch clause variables as 'unknown' instead of 'any'. */ + // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */ + "noUnusedLocals": false, /* Enable error reporting when local variables aren't read. */ + "noUnusedParameters": false, /* Raise an error when a function parameter isn't read. */ + // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */ + // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */ + // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */ + // "noUncheckedIndexedAccess": true, /* Add 'undefined' to a type when accessed using an index. */ + // "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */ + // "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type. */ + // "allowUnusedLabels": true, /* Disable error reporting for unused labels. */ + // "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */ + + /* Completeness */ + // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */ + "skipLibCheck": true, /* Skip type checking all .d.ts files. */ + /* - * TODO: remove importsNotUsedAsValues after typescript 5.5 and up as it will no longer work. If we want the same behavior - * as importsNotUsedAsValues, we need to use "verbatimModuleSyntax", which will require this package to be an ES Module. - */ - "importsNotUsedAsValues": "error", - "resolveJsonModule": true + * TODO: remove ignoreDeprecations after typescript 5.5. This is used to assist in the transition to typescript 5.5 and up. + */ + "ignoreDeprecations": "5.0", } }