diff --git a/package.json b/package.json index abeb14d72..995544618 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "lint": "prettier --check ." }, "dependencies": { - "typescript": "^5.3.2" + "typescript": "^5.4.5" }, "devDependencies": { "cross-env": "^7.0.2", diff --git a/packages/language-server/package.json b/packages/language-server/package.json index 8908da6e5..45de36a36 100644 --- a/packages/language-server/package.json +++ b/packages/language-server/package.json @@ -57,7 +57,7 @@ "svelte": "^3.57.0", "svelte-preprocess": "^5.1.3", "svelte2tsx": "workspace:~", - "typescript": "~5.3.2", + "typescript": "^5.3.2", "typescript-auto-import-cache": "^0.3.2", "vscode-css-languageservice": "~6.2.10", "vscode-html-languageservice": "~5.1.1", diff --git a/packages/language-server/src/plugins/typescript/module-loader.ts b/packages/language-server/src/plugins/typescript/module-loader.ts index 6f1fe5e39..91e59827b 100644 --- a/packages/language-server/src/plugins/typescript/module-loader.ts +++ b/packages/language-server/src/plugins/typescript/module-loader.ts @@ -107,7 +107,6 @@ class ImpliedNodeFormatResolver { let mode = undefined; if (sourceFile) { this.cacheImpliedNodeFormat(sourceFile, compilerOptions); - // @ts-expect-error remove when bumping to TS 5.4 mode = ts.getModeForResolutionAtIndex(sourceFile, importIdxInFile, compilerOptions); } return mode; diff --git a/packages/language-server/test/plugins/typescript/features/diagnostics/fixtures/style-directive/expectedv2.json b/packages/language-server/test/plugins/typescript/features/diagnostics/fixtures/style-directive/expectedv2.json index cc0a854be..7463797a3 100644 --- a/packages/language-server/test/plugins/typescript/features/diagnostics/fixtures/style-directive/expectedv2.json +++ b/packages/language-server/test/plugins/typescript/features/diagnostics/fixtures/style-directive/expectedv2.json @@ -6,7 +6,7 @@ }, "severity": 1, "source": "ts", - "message": "Argument of type 'boolean' is not assignable to parameter of type 'String | Number | null | undefined'.", + "message": "Argument of type 'true' is not assignable to parameter of type 'String | Number | null | undefined'.", "code": 2345, "tags": [] }, @@ -17,7 +17,7 @@ }, "severity": 1, "source": "ts", - "message": "Argument of type 'boolean' is not assignable to parameter of type 'String | Number | null | undefined'.", + "message": "Argument of type 'true' is not assignable to parameter of type 'String | Number | null | undefined'.", "code": 2345, "tags": [] } diff --git a/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/component-handler/expectedv2.json b/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/component-handler/expectedv2.json index 7d567c1c2..56478c66d 100644 --- a/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/component-handler/expectedv2.json +++ b/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/component-handler/expectedv2.json @@ -12,8 +12,8 @@ "value": "MouseEvent", "location": { "range": { - "start": { "line": 15586, "character": 10 }, - "end": { "line": 15586, "character": 20 } + "start": { "line": 15692, "character": 10 }, + "end": { "line": 15692, "character": 20 } }, "uri": "/typescript/lib/lib.dom.d.ts" } diff --git a/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/element-handler/expectedv2.json b/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/element-handler/expectedv2.json index f736e622c..86a02a272 100644 --- a/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/element-handler/expectedv2.json +++ b/packages/language-server/test/plugins/typescript/features/inlayHints/fixtures/element-handler/expectedv2.json @@ -6,8 +6,8 @@ "value": "MouseEvent", "location": { "range": { - "start": { "line": 15586, "character": 10 }, - "end": { "line": 15586, "character": 20 } + "start": { "line": 15692, "character": 10 }, + "end": { "line": 15692, "character": 20 } }, "uri": "/typescript/lib/lib.dom.d.ts" } @@ -21,8 +21,8 @@ "value": "EventTarget", "location": { "range": { - "start": { "line": 8192, "character": 10 }, - "end": { "line": 8192, "character": 21 } + "start": { "line": 8237, "character": 10 }, + "end": { "line": 8237, "character": 21 } }, "uri": "/typescript/lib/lib.dom.d.ts" } @@ -32,8 +32,8 @@ "value": "HTMLButtonElement", "location": { "range": { - "start": { "line": 9684, "character": 10 }, - "end": { "line": 9684, "character": 27 } + "start": { "line": 9732, "character": 10 }, + "end": { "line": 9732, "character": 27 } }, "uri": "/typescript/lib/lib.dom.d.ts" } diff --git a/packages/svelte-vscode/package.json b/packages/svelte-vscode/package.json index 250a8063a..b143bb636 100644 --- a/packages/svelte-vscode/package.json +++ b/packages/svelte-vscode/package.json @@ -719,7 +719,7 @@ "@types/vscode": "^1.67", "js-yaml": "^3.14.0", "tslib": "^2.4.0", - "typescript": "~5.3.2", + "typescript": "^5.4.5", "vscode-tmgrammar-test": "^0.0.11" }, "dependencies": { diff --git a/packages/svelte2tsx/package.json b/packages/svelte2tsx/package.json index 4c226dc9f..daef29560 100644 --- a/packages/svelte2tsx/package.json +++ b/packages/svelte2tsx/package.json @@ -40,7 +40,7 @@ "svelte": "~3.57.0", "tiny-glob": "^0.2.6", "tslib": "^2.4.0", - "typescript": "^5.3.2" + "typescript": "^5.4.5" }, "peerDependencies": { "svelte": "^3.55 || ^4.0.0-next.0 || ^4.0 || ^5.0.0-next.0", diff --git a/packages/typescript-plugin/package.json b/packages/typescript-plugin/package.json index e47708ffa..505f9b5d7 100644 --- a/packages/typescript-plugin/package.json +++ b/packages/typescript-plugin/package.json @@ -19,7 +19,7 @@ "license": "MIT", "devDependencies": { "@types/node": "^16.0.0", - "typescript": "^5.3.2" + "typescript": "^5.4.5" }, "dependencies": { "@jridgewell/sourcemap-codec": "^1.4.14", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 9734f0359..b1b05e2d6 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -9,8 +9,8 @@ importers: .: dependencies: typescript: - specifier: ^5.3.2 - version: 5.3.2 + specifier: ^5.4.5 + version: 5.4.5 devDependencies: cross-env: specifier: ^7.0.2 @@ -20,7 +20,7 @@ importers: version: 3.2.5 ts-node: specifier: ^10.0.0 - version: 10.9.1(@types/node@16.18.32)(typescript@5.3.2) + version: 10.9.1(@types/node@16.18.32)(typescript@5.4.5) packages/language-server: dependencies: @@ -53,13 +53,13 @@ importers: version: 3.57.0 svelte-preprocess: specifier: ^5.1.3 - version: 5.1.3(svelte@3.57.0)(typescript@5.3.2) + version: 5.1.3(svelte@3.57.0)(typescript@5.4.5) svelte2tsx: specifier: workspace:~ version: link:../svelte2tsx typescript: - specifier: ~5.3.2 - version: 5.3.2 + specifier: ^5.3.2 + version: 5.4.5 typescript-auto-import-cache: specifier: ^0.3.2 version: 0.3.2 @@ -111,7 +111,7 @@ importers: version: 11.1.2 ts-node: specifier: ^10.0.0 - version: 10.9.1(@types/node@16.18.32)(typescript@5.3.2) + version: 10.9.1(@types/node@16.18.32)(typescript@5.4.5) packages/svelte-check: dependencies: @@ -138,10 +138,10 @@ importers: version: 3.57.0 svelte-preprocess: specifier: ^5.1.3 - version: 5.1.3(svelte@3.57.0)(typescript@5.3.2) + version: 5.1.3(svelte@3.57.0)(typescript@5.4.5) typescript: specifier: ^5.0.3 - version: 5.3.2 + version: 5.4.5 devDependencies: '@rollup/plugin-commonjs': specifier: ^24.0.0 @@ -157,7 +157,7 @@ importers: version: 5.0.2(rollup@3.7.5) '@rollup/plugin-typescript': specifier: ^10.0.0 - version: 10.0.1(rollup@3.7.5)(tslib@2.5.2)(typescript@5.3.2) + version: 10.0.1(rollup@3.7.5)(tslib@2.5.2)(typescript@5.4.5) '@types/sade': specifier: ^1.7.2 version: 1.7.4 @@ -223,8 +223,8 @@ importers: specifier: ^2.4.0 version: 2.5.2 typescript: - specifier: ~5.3.2 - version: 5.3.2 + specifier: ^5.4.5 + version: 5.4.5 vscode-tmgrammar-test: specifier: ^0.0.11 version: 0.0.11 @@ -255,7 +255,7 @@ importers: version: 15.0.2(rollup@3.7.5) '@rollup/plugin-typescript': specifier: ^10.0.0 - version: 10.0.1(rollup@3.7.5)(tslib@2.5.2)(typescript@5.3.2) + version: 10.0.1(rollup@3.7.5)(tslib@2.5.2)(typescript@5.4.5) '@types/estree': specifier: ^0.0.42 version: 0.0.42 @@ -305,8 +305,8 @@ importers: specifier: ^2.4.0 version: 2.5.2 typescript: - specifier: ^5.3.2 - version: 5.3.2 + specifier: ^5.4.5 + version: 5.4.5 packages/typescript-plugin: dependencies: @@ -321,8 +321,8 @@ importers: specifier: ^16.0.0 version: 16.18.32 typescript: - specifier: ^5.3.2 - version: 5.3.2 + specifier: ^5.4.5 + version: 5.4.5 packages: @@ -458,7 +458,7 @@ packages: rollup: 3.7.5 dev: true - /@rollup/plugin-typescript@10.0.1(rollup@3.7.5)(tslib@2.5.2)(typescript@5.3.2): + /@rollup/plugin-typescript@10.0.1(rollup@3.7.5)(tslib@2.5.2)(typescript@5.4.5): resolution: {integrity: sha512-wBykxRLlX7EzL8BmUqMqk5zpx2onnmRMSw/l9M1sVfkJvdwfxogZQVNUM9gVMJbjRLDR5H6U0OMOrlDGmIV45A==} engines: {node: '>=14.0.0'} peerDependencies: @@ -475,7 +475,7 @@ packages: resolve: 1.22.2 rollup: 3.7.5 tslib: 2.5.2 - typescript: 5.3.2 + typescript: 5.4.5 dev: true /@rollup/pluginutils@5.0.2(rollup@3.7.5): @@ -1832,7 +1832,7 @@ packages: engines: {node: '>= 0.4'} dev: true - /svelte-preprocess@5.1.3(svelte@3.57.0)(typescript@5.3.2): + /svelte-preprocess@5.1.3(svelte@3.57.0)(typescript@5.4.5): resolution: {integrity: sha512-xxAkmxGHT+J/GourS5mVJeOXZzne1FR5ljeOUAMXUkfEhkLEllRreXpbl3dIYJlcJRfL1LO1uIAPpBpBfiqGPw==} engines: {node: '>= 16.0.0', pnpm: ^8.0.0} requiresBuild: true @@ -1876,7 +1876,7 @@ packages: sorcery: 0.11.0 strip-indent: 3.0.0 svelte: 3.57.0 - typescript: 5.3.2 + typescript: 5.4.5 dev: false /svelte@3.57.0: @@ -1896,7 +1896,7 @@ packages: dependencies: is-number: 7.0.0 - /ts-node@10.9.1(@types/node@16.18.32)(typescript@5.3.2): + /ts-node@10.9.1(@types/node@16.18.32)(typescript@5.4.5): resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==} hasBin: true peerDependencies: @@ -1922,7 +1922,7 @@ packages: create-require: 1.1.1 diff: 4.0.2 make-error: 1.3.6 - typescript: 5.3.2 + typescript: 5.4.5 v8-compile-cache-lib: 3.0.1 yn: 3.1.1 dev: true @@ -1941,8 +1941,8 @@ packages: semver: 7.5.1 dev: false - /typescript@5.3.2: - resolution: {integrity: sha512-6l+RyNy7oAHDfxC4FzSJcz9vnjTKxrLpDG5M2Vu4SHRVNg6xzqZp6LYSR9zjqQTu8DU/f5xwxUdADOkbrIX2gQ==} + /typescript@5.4.5: + resolution: {integrity: sha512-vcI4UpRgg81oIRUFwR0WSIHKt11nJ7SAVlYNIu+QpqeyXP+gpQJy/Z4+F0aGxSE4MqwjyXvW/TzgkLAx2AGHwQ==} engines: {node: '>=14.17'} hasBin: true