From 457fc38e6a4b99ddf500352c8b60e2287e922498 Mon Sep 17 00:00:00 2001 From: Hazelnoot Date: Tue, 30 Sep 2025 20:11:59 -0400 Subject: [PATCH] normalize more TS configs --- cypress/tsconfig.json | 7 ++++--- packages/backend/jsconfig.json | 10 +++++++--- packages/backend/test-federation/tsconfig.json | 2 +- packages/frontend/test/tsconfig.json | 1 + packages/misskey-js/generator/tsconfig.json | 5 +++-- 5 files changed, 16 insertions(+), 9 deletions(-) diff --git a/cypress/tsconfig.json b/cypress/tsconfig.json index 4435a4fda8..e61061f41c 100644 --- a/cypress/tsconfig.json +++ b/cypress/tsconfig.json @@ -1,9 +1,10 @@ { "compilerOptions": { - "lib": ["dom", "es5"], - "target": "es5", + "lib": ["dom", "ES2022"], + "target": "ES2022", "types": ["cypress", "node"], - "incremental": true + "incremental": true, + "skipLibCheck": true, }, "include": ["./**/*.ts"] } diff --git a/packages/backend/jsconfig.json b/packages/backend/jsconfig.json index 1230aadd12..0f72af1f8a 100644 --- a/packages/backend/jsconfig.json +++ b/packages/backend/jsconfig.json @@ -1,8 +1,12 @@ { "compilerOptions": { - "target": "es6", - "module": "commonjs", - "allowSyntheticDefaultImports": true + "target": "ES2022", + "module": "NodeNext", + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, + "skipLibCheck": true, + "allowJs": true, + "checkJs": true }, "exclude": [ "node_modules", diff --git a/packages/backend/test-federation/tsconfig.json b/packages/backend/test-federation/tsconfig.json index 16b333f877..df2d4bb97d 100644 --- a/packages/backend/test-federation/tsconfig.json +++ b/packages/backend/test-federation/tsconfig.json @@ -11,7 +11,7 @@ // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */ /* Language and Environment */ - "target": "ESNext", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */ + "target": "ES2022", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */ // "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ // "jsx": "preserve", /* Specify what JSX code is generated. */ // "experimentalDecorators": true, /* Enable experimental support for legacy experimental decorators. */ diff --git a/packages/frontend/test/tsconfig.json b/packages/frontend/test/tsconfig.json index 1490a66d20..f8a73b8e21 100644 --- a/packages/frontend/test/tsconfig.json +++ b/packages/frontend/test/tsconfig.json @@ -22,6 +22,7 @@ "emitDecoratorMetadata": true, "resolveJsonModule": true, "isolatedModules": true, + "skipLibCheck": true, "incremental": true, "baseUrl": "./", "paths": { diff --git a/packages/misskey-js/generator/tsconfig.json b/packages/misskey-js/generator/tsconfig.json index 0de2a7fe77..7accd8d10d 100644 --- a/packages/misskey-js/generator/tsconfig.json +++ b/packages/misskey-js/generator/tsconfig.json @@ -1,12 +1,13 @@ { "$schema": "https://json.schemastore.org/tsconfig", "compilerOptions": { - "target": "ESNext", + "target": "ES2022", "module": "ESNext", - "moduleResolution": "node16", + "moduleResolution": "nodenext", "strict": true, "strictFunctionTypes": true, "strictNullChecks": true, + "skipLibCheck": true, "esModuleInterop": true, "incremental": true, "lib": [