diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index af422918..3c8a2adb 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -26,6 +26,11 @@ deno task bundle The build checks DOM and Web Worker consumers in `tests/types/public-api.ts`, including the distinction between type-only and runtime exports. +Declaration generation requires TypeScript's JavaScript compiler API. The build +uses TypeScript 6; TypeScript 7's native API is not a drop-in replacement. This +restriction does not limit the TypeScript versions supported by library +consumers. + **How to check if your new code is standard JS style** ```bash diff --git a/build/bun.lock b/build/bun.lock index 79b68eb8..2dda0ad9 100644 --- a/build/bun.lock +++ b/build/bun.lock @@ -5,14 +5,11 @@ "": { "name": "@poolifier/poolifier-web-worker-build", "dependencies": { - "typescript": "^7.0.2", + "typescript": "^6.0.3", }, }, }, - "overrides": { - "typescript": "^5.9.3", - }, "packages": { - "typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="], + "typescript": ["typescript@6.0.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-y2TvuxSZPDyQakkFRPZHKFm+KKVqIisdg9/CZwm9ftvKXLP8NRWj38/ODjNbr43SsoXqNuAisEf1GdCxqWcdBw=="], } } diff --git a/build/package.json b/build/package.json index 4746d82b..3e8fcdbf 100644 --- a/build/package.json +++ b/build/package.json @@ -5,15 +5,6 @@ "private": true, "type": "module", "dependencies": { - "typescript": "^7.0.2" - }, - "overrides": { - "typescript": "^5.9.3" - }, - "overrides": { - "typescript": "^5.9.3" - }, - "overrides": { - "typescript": "^7.0.0" + "typescript": "^6.0.3" } } diff --git a/renovate.json b/renovate.json index 08ab1f89..6a4666b3 100644 --- a/renovate.json +++ b/renovate.json @@ -27,6 +27,12 @@ { "matchFileNames": ["**/deno.json"], "rangeStrategy": "bump" + }, + { + "description": "Keep the build on the JavaScript compiler API; TypeScript 7 is not API-compatible.", + "matchFileNames": ["build/package.json"], + "matchPackageNames": ["typescript"], + "allowedVersions": "<7" } ], "ignorePaths": [