diff --git a/AGENTS.md b/AGENTS.md index 6bfc8cdd6..b6ef44dcc 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -37,7 +37,7 @@ npm run test:e2e npm test # Check JSDoc comment syntax and `{@link}` references -npm exec typedoc -- --treatValidationWarningsAsErrors --emit none +npm run docs -- --treatValidationWarningsAsErrors --emit none # Regenerate package-lock.json # Note: repo .npmrc pins registry to npmjs.org, so a plain `npm i` is safe even @@ -85,7 +85,7 @@ View (App) <--PostMessageTransport--> Host (AppBridge) <--MCP Client--> MCP Serv JSDoc `@example` tags should pull type-checked code from companion `.examples.ts` files (e.g., `app.ts` → `app.examples.ts`). Use ` ```ts source="./file.examples.ts#regionName" ` fences referencing `//#region regionName` blocks; region names follow `exportedName_variant` or `ClassName_methodName_variant` pattern (e.g., `useApp_basicUsage`, `App_hostCapabilities_checkAfterConnection`). For whole-file inclusion (any file type), omit the `#regionName`. Run `npm run sync:snippets` to sync. -Standalone docs in `docs/` (listed in `typedoc.config.mjs` `projectDocuments`) can also have type-checked companion `.ts`/`.tsx` files using the same pattern. +Standalone docs in `docs/` (listed in `typedoc.config.ts` `projectDocuments`) can also have type-checked companion `.ts`/`.tsx` files using the same pattern. ## Full Examples diff --git a/build.bun.ts b/build.bun.ts index a129d5ddd..77f7e10fb 100644 --- a/build.bun.ts +++ b/build.bun.ts @@ -2,8 +2,9 @@ import { $ } from "bun"; import { cpSync, mkdirSync } from "node:fs"; -// Run TypeScript compiler for type declarations -await $`tsc`; +// TypeDoc and declaration emit still require TypeScript's JavaScript compiler API. +// Keep this compatibility lane explicit while native TypeScript 7 checks source. +await $`node node_modules/typescript/bin/tsc`; // Copy schema.json (tsc is emitDeclarationOnly, Bun.build doesn't emit JSON assets). // Needed for the "./schema.json" package export. diff --git a/docs/quickstart.md b/docs/quickstart.md index 3e00796c5..08c6e084a 100644 --- a/docs/quickstart.md +++ b/docs/quickstart.md @@ -63,6 +63,7 @@ npm pkg set scripts.start='concurrently --raw "cross-env NODE_ENV=development IN "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, @@ -91,6 +92,7 @@ npm pkg set scripts.start='concurrently --raw "cross-env NODE_ENV=development IN "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/basic-host/package.json b/examples/basic-host/package.json index 1b45dcf18..6ff5a5229 100644 --- a/examples/basic-host/package.json +++ b/examples/basic-host/package.json @@ -27,7 +27,7 @@ "cors": "^2.8.5", "express": "^5.1.0", "prettier": "^3.6.2", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } diff --git a/examples/basic-host/src/implementation.ts b/examples/basic-host/src/implementation.ts index 31e36983e..25efb3a56 100644 --- a/examples/basic-host/src/implementation.ts +++ b/examples/basic-host/src/implementation.ts @@ -7,7 +7,7 @@ import { getTheme, onThemeChange } from "./theme"; import { HOST_STYLE_VARIABLES } from "./host-styles"; -const SANDBOX_PROXY_BASE_URL = "http://localhost:8081/sandbox.html"; +const SANDBOX_PROXY_BASE_URL = `http://localhost:${import.meta.env.VITE_SANDBOX_PORT ?? "8081"}/sandbox.html`; const IMPLEMENTATION = { name: "MCP Apps Host", version: "1.0.0" }; diff --git a/examples/basic-host/tsconfig.json b/examples/basic-host/tsconfig.json index 9d7c3bcad..ce04cd89a 100644 --- a/examples/basic-host/tsconfig.json +++ b/examples/basic-host/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "resolveJsonModule": true, "isolatedModules": true, "verbatimModuleSyntax": true, diff --git a/examples/basic-server-preact/package.json b/examples/basic-server-preact/package.json index 512720205..94bc5751a 100644 --- a/examples/basic-server-preact/package.json +++ b/examples/basic-server-preact/package.json @@ -38,7 +38,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/basic-server-preact/tsconfig.json b/examples/basic-server-preact/tsconfig.json index 32182d918..14d99f793 100644 --- a/examples/basic-server-preact/tsconfig.json +++ b/examples/basic-server-preact/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/basic-server-preact/tsconfig.server.json b/examples/basic-server-preact/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/basic-server-preact/tsconfig.server.json +++ b/examples/basic-server-preact/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/basic-server-react/package.json b/examples/basic-server-react/package.json index e4d12333f..0d5f7a33f 100644 --- a/examples/basic-server-react/package.json +++ b/examples/basic-server-react/package.json @@ -51,7 +51,7 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } diff --git a/examples/basic-server-react/tsconfig.json b/examples/basic-server-react/tsconfig.json index fc3c2101f..c98416d4b 100644 --- a/examples/basic-server-react/tsconfig.json +++ b/examples/basic-server-react/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/basic-server-react/tsconfig.server.json b/examples/basic-server-react/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/basic-server-react/tsconfig.server.json +++ b/examples/basic-server-react/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/basic-server-solid/package.json b/examples/basic-server-solid/package.json index 8f75ac8c2..0898ec273 100644 --- a/examples/basic-server-solid/package.json +++ b/examples/basic-server-solid/package.json @@ -37,7 +37,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0", "vite-plugin-solid": "^2.11.12" diff --git a/examples/basic-server-solid/tsconfig.json b/examples/basic-server-solid/tsconfig.json index 84f0efe14..c53e77553 100644 --- a/examples/basic-server-solid/tsconfig.json +++ b/examples/basic-server-solid/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/basic-server-solid/tsconfig.server.json b/examples/basic-server-solid/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/basic-server-solid/tsconfig.server.json +++ b/examples/basic-server-solid/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/basic-server-svelte/package.json b/examples/basic-server-svelte/package.json index f877bf7c8..68ce55acf 100644 --- a/examples/basic-server-svelte/package.json +++ b/examples/basic-server-svelte/package.json @@ -38,7 +38,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/basic-server-svelte/svelte.config.js b/examples/basic-server-svelte/svelte.config.ts similarity index 100% rename from examples/basic-server-svelte/svelte.config.js rename to examples/basic-server-svelte/svelte.config.ts diff --git a/examples/basic-server-svelte/tsconfig.json b/examples/basic-server-svelte/tsconfig.json index 5edb66a8a..149a8db94 100644 --- a/examples/basic-server-svelte/tsconfig.json +++ b/examples/basic-server-svelte/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/basic-server-svelte/tsconfig.server.json b/examples/basic-server-svelte/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/basic-server-svelte/tsconfig.server.json +++ b/examples/basic-server-svelte/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/basic-server-vanillajs/package.json b/examples/basic-server-vanillajs/package.json index 5d47f2cdc..26f22e512 100644 --- a/examples/basic-server-vanillajs/package.json +++ b/examples/basic-server-vanillajs/package.json @@ -36,7 +36,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/basic-server-vanillajs/tsconfig.json b/examples/basic-server-vanillajs/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/basic-server-vanillajs/tsconfig.json +++ b/examples/basic-server-vanillajs/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/basic-server-vanillajs/tsconfig.server.json b/examples/basic-server-vanillajs/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/basic-server-vanillajs/tsconfig.server.json +++ b/examples/basic-server-vanillajs/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/basic-server-vue/package.json b/examples/basic-server-vue/package.json index d27ddc91b..73abda180 100644 --- a/examples/basic-server-vue/package.json +++ b/examples/basic-server-vue/package.json @@ -38,7 +38,7 @@ "@vitejs/plugin-vue": "^5.0.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/basic-server-vue/tsconfig.json b/examples/basic-server-vue/tsconfig.json index 5edb66a8a..149a8db94 100644 --- a/examples/basic-server-vue/tsconfig.json +++ b/examples/basic-server-vue/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/basic-server-vue/tsconfig.server.json b/examples/basic-server-vue/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/basic-server-vue/tsconfig.server.json +++ b/examples/basic-server-vue/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/budget-allocator-server/package.json b/examples/budget-allocator-server/package.json index 19a1d2554..d2ccc2fee 100644 --- a/examples/budget-allocator-server/package.json +++ b/examples/budget-allocator-server/package.json @@ -39,7 +39,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/budget-allocator-server/tsconfig.json b/examples/budget-allocator-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/budget-allocator-server/tsconfig.json +++ b/examples/budget-allocator-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/budget-allocator-server/tsconfig.server.json b/examples/budget-allocator-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/budget-allocator-server/tsconfig.server.json +++ b/examples/budget-allocator-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/cohort-heatmap-server/package.json b/examples/cohort-heatmap-server/package.json index 8d1268b5c..e353898e7 100644 --- a/examples/cohort-heatmap-server/package.json +++ b/examples/cohort-heatmap-server/package.json @@ -43,7 +43,7 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/cohort-heatmap-server/tsconfig.json b/examples/cohort-heatmap-server/tsconfig.json index fc3c2101f..c98416d4b 100644 --- a/examples/cohort-heatmap-server/tsconfig.json +++ b/examples/cohort-heatmap-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/cohort-heatmap-server/tsconfig.server.json b/examples/cohort-heatmap-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/cohort-heatmap-server/tsconfig.server.json +++ b/examples/cohort-heatmap-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/customer-segmentation-server/package.json b/examples/customer-segmentation-server/package.json index 4511de903..ddf8b11cb 100644 --- a/examples/customer-segmentation-server/package.json +++ b/examples/customer-segmentation-server/package.json @@ -39,7 +39,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/customer-segmentation-server/tsconfig.json b/examples/customer-segmentation-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/customer-segmentation-server/tsconfig.json +++ b/examples/customer-segmentation-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/customer-segmentation-server/tsconfig.server.json b/examples/customer-segmentation-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/customer-segmentation-server/tsconfig.server.json +++ b/examples/customer-segmentation-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/debug-server/package.json b/examples/debug-server/package.json index 3417a8fe9..ff4bb10ef 100644 --- a/examples/debug-server/package.json +++ b/examples/debug-server/package.json @@ -46,7 +46,7 @@ "cors": "^2.8.5", "cross-env": "^10.1.0", "express": "^5.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } diff --git a/examples/debug-server/tsconfig.json b/examples/debug-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/debug-server/tsconfig.json +++ b/examples/debug-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/debug-server/tsconfig.server.json b/examples/debug-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/debug-server/tsconfig.server.json +++ b/examples/debug-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/integration-server/package.json b/examples/integration-server/package.json index f6715a4ff..af09140e7 100644 --- a/examples/integration-server/package.json +++ b/examples/integration-server/package.json @@ -31,7 +31,7 @@ "@types/react-dom": "^19.2.2", "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/integration-server/tsconfig.json b/examples/integration-server/tsconfig.json index fc3c2101f..c98416d4b 100644 --- a/examples/integration-server/tsconfig.json +++ b/examples/integration-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/integration-server/tsconfig.server.json b/examples/integration-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/integration-server/tsconfig.server.json +++ b/examples/integration-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/lazy-auth-server/package.json b/examples/lazy-auth-server/package.json index f3ed6cd27..74a66d42e 100644 --- a/examples/lazy-auth-server/package.json +++ b/examples/lazy-auth-server/package.json @@ -34,7 +34,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/lazy-auth-server/tsconfig.json b/examples/lazy-auth-server/tsconfig.json index 6c553b5d7..da295c784 100644 --- a/examples/lazy-auth-server/tsconfig.json +++ b/examples/lazy-auth-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/lazy-auth-server/tsconfig.server.json b/examples/lazy-auth-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/lazy-auth-server/tsconfig.server.json +++ b/examples/lazy-auth-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/map-server/package.json b/examples/map-server/package.json index 5dc23fe20..bf8ff756f 100644 --- a/examples/map-server/package.json +++ b/examples/map-server/package.json @@ -38,7 +38,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/map-server/tsconfig.json b/examples/map-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/map-server/tsconfig.json +++ b/examples/map-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/map-server/tsconfig.server.json b/examples/map-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/map-server/tsconfig.server.json +++ b/examples/map-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/pdf-server/build-mcpb.mjs b/examples/pdf-server/build-mcpb.ts similarity index 95% rename from examples/pdf-server/build-mcpb.mjs rename to examples/pdf-server/build-mcpb.ts index c1c346909..10bbcf505 100644 --- a/examples/pdf-server/build-mcpb.mjs +++ b/examples/pdf-server/build-mcpb.ts @@ -45,7 +45,7 @@ writeFileSync( ); writeFileSync(path.join(stage, "package.json"), JSON.stringify(pkg, null, 2)); -const run = (cmd) => execSync(cmd, { cwd: stage, stdio: "inherit" }); +const run = (cmd: string) => execSync(cmd, { cwd: stage, stdio: "inherit" }); run( "npm install --omit=dev --omit=optional --no-audit --no-fund --no-package-lock " + "--registry=https://registry.npmjs.org/", diff --git a/examples/pdf-server/package.json b/examples/pdf-server/package.json index 4d960f175..830b8ffc4 100644 --- a/examples/pdf-server/package.json +++ b/examples/pdf-server/package.json @@ -22,7 +22,7 @@ "start:stdio": "cross-env NODE_ENV=development npm run build 1>&2 && npm run serve:stdio", "dev": "cross-env NODE_ENV=development concurrently \"npm run watch\" \"npm run serve\"", "prepublishOnly": "npm run build", - "build:mcpb": "npm run build && node build-mcpb.mjs" + "build:mcpb": "npm run build && node --import tsx build-mcpb.ts" }, "dependencies": { "@cantoo/pdf-lib": "^2.6.5", @@ -39,7 +39,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/pdf-server/tsconfig.json b/examples/pdf-server/tsconfig.json index 050182789..34032206a 100644 --- a/examples/pdf-server/tsconfig.json +++ b/examples/pdf-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client", "bun"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "verbatimModuleSyntax": true, diff --git a/examples/pdf-server/tsconfig.server.json b/examples/pdf-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/pdf-server/tsconfig.server.json +++ b/examples/pdf-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/quickstart/package.json b/examples/quickstart/package.json index 99948cc2d..077d0f8d6 100644 --- a/examples/quickstart/package.json +++ b/examples/quickstart/package.json @@ -27,7 +27,7 @@ "concurrently": "^9.2.1", "cross-env": "^10.1.0", "tsx": "^4.21.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } diff --git a/examples/quickstart/tsconfig.json b/examples/quickstart/tsconfig.json index 6c553b5d7..da295c784 100644 --- a/examples/quickstart/tsconfig.json +++ b/examples/quickstart/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/quickstart/tsconfig.server.json b/examples/quickstart/tsconfig.server.json index 7e65f5f75..023019fe1 100644 --- a/examples/quickstart/tsconfig.server.json +++ b/examples/quickstart/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/run-all.ts b/examples/run-all.ts index 876655e18..81a37d468 100644 --- a/examples/run-all.ts +++ b/examples/run-all.ts @@ -11,7 +11,7 @@ * EXAMPLE= - Run only a single example (e.g., EXAMPLE=say-server) */ -import { readdirSync, statSync, existsSync } from "fs"; +import { readdirSync, statSync, existsSync, readFileSync } from "fs"; import concurrently from "concurrently"; const BASE_PORT = 3101; @@ -19,6 +19,12 @@ const BASIC_HOST = "basic-host"; // Optional: filter to a single example via EXAMPLE env var (folder name) const EXAMPLE_FILTER = process.env.EXAMPLE; +const EXCLUDED_EXAMPLES = new Set( + (process.env.EXCLUDE_EXAMPLES ?? "") + .split(",") + .map((example) => example.trim()) + .filter(Boolean), +); // Find all example directories except basic-host that have a package.json, // assign ports, and build URL list @@ -34,7 +40,7 @@ const allServers = readdirSync("examples") // Filter servers if EXAMPLE is specified const filteredDirs = EXAMPLE_FILTER ? allServers.filter((d) => d === EXAMPLE_FILTER) - : allServers; + : allServers.filter((d) => !EXCLUDED_EXAMPLES.has(d)); if (EXAMPLE_FILTER && filteredDirs.length === 0) { console.error(`Error: No example found matching EXAMPLE=${EXAMPLE_FILTER}`); @@ -48,7 +54,7 @@ const servers = filteredDirs.map((dir, i) => ({ url: `http://localhost:${BASE_PORT + i}/mcp`, })); -const COMMANDS = ["start", "dev", "build"]; +const COMMANDS = ["start", "dev", "build", "serve"]; const command = process.argv[2]; @@ -60,6 +66,18 @@ if (!command || !COMMANDS.includes(command)) { // Build the SERVERS environment variable (JSON array of URLs) const serversEnv = JSON.stringify(servers.map((s) => s.url)); +const getWorkspaceCommand = (dir: string) => { + if (command !== "serve") return command; + + const packageJson = JSON.parse( + readFileSync(`examples/${dir}/package.json`, "utf8"), + ) as { scripts?: Record }; + + if (packageJson.scripts?.["serve:http"]) return "serve:http"; + if (packageJson.scripts?.serve) return "serve"; + return "start"; +}; + console.log(`Running command: ${command}`); if (EXAMPLE_FILTER) { console.log(`Filtering to single example: ${EXAMPLE_FILTER}`); @@ -73,13 +91,13 @@ console.log(""); const commands: Parameters[0] = [ // Server examples ...servers.map(({ dir, port }) => ({ - command: `npm run --workspace examples/${dir} ${command}`, + command: `npm run --workspace examples/${dir} ${getWorkspaceCommand(dir)}`, name: dir, env: { PORT: String(port) }, })), // Basic host with SERVERS env { - command: `npm run --workspace examples/${BASIC_HOST} ${command}`, + command: `npm run --workspace examples/${BASIC_HOST} ${getWorkspaceCommand(BASIC_HOST)}`, name: BASIC_HOST, env: { SERVERS: serversEnv }, }, @@ -96,7 +114,11 @@ if (command === "dev") { const { result } = concurrently(commands, { prefix: "name", // For build command, we want all to complete; for start/dev, kill all on failure - killOthersOnFail: command !== "build", + killOthersOn: command !== "build" ? ["failure"] : [], + maxProcesses: + command === "build" + ? Number(process.env.EXAMPLES_BUILD_CONCURRENCY ?? "4") + : undefined, }); result.catch(() => process.exit(1)); diff --git a/examples/scenario-modeler-server/package.json b/examples/scenario-modeler-server/package.json index aa1e668ef..8971f2b52 100644 --- a/examples/scenario-modeler-server/package.json +++ b/examples/scenario-modeler-server/package.json @@ -44,7 +44,7 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/scenario-modeler-server/tsconfig.json b/examples/scenario-modeler-server/tsconfig.json index fc3c2101f..c98416d4b 100644 --- a/examples/scenario-modeler-server/tsconfig.json +++ b/examples/scenario-modeler-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/scenario-modeler-server/tsconfig.server.json b/examples/scenario-modeler-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/scenario-modeler-server/tsconfig.server.json +++ b/examples/scenario-modeler-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/shadertoy-server/package.json b/examples/shadertoy-server/package.json index ccf15a45c..a67080119 100644 --- a/examples/shadertoy-server/package.json +++ b/examples/shadertoy-server/package.json @@ -36,7 +36,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/shadertoy-server/tsconfig.json b/examples/shadertoy-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/shadertoy-server/tsconfig.json +++ b/examples/shadertoy-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/shadertoy-server/tsconfig.server.json b/examples/shadertoy-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/shadertoy-server/tsconfig.server.json +++ b/examples/shadertoy-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/sheet-music-server/package.json b/examples/sheet-music-server/package.json index ca9fa909f..7e08d7666 100644 --- a/examples/sheet-music-server/package.json +++ b/examples/sheet-music-server/package.json @@ -37,7 +37,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/sheet-music-server/tsconfig.json b/examples/sheet-music-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/sheet-music-server/tsconfig.json +++ b/examples/sheet-music-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/sheet-music-server/tsconfig.server.json b/examples/sheet-music-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/sheet-music-server/tsconfig.server.json +++ b/examples/sheet-music-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/system-monitor-server/package.json b/examples/system-monitor-server/package.json index 12e8cea06..b3143e68a 100644 --- a/examples/system-monitor-server/package.json +++ b/examples/system-monitor-server/package.json @@ -40,7 +40,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/system-monitor-server/tsconfig.json b/examples/system-monitor-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/system-monitor-server/tsconfig.json +++ b/examples/system-monitor-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/system-monitor-server/tsconfig.server.json b/examples/system-monitor-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/system-monitor-server/tsconfig.server.json +++ b/examples/system-monitor-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/threejs-server/package.json b/examples/threejs-server/package.json index cfb5686a6..16a38b024 100644 --- a/examples/threejs-server/package.json +++ b/examples/threejs-server/package.json @@ -45,7 +45,7 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/threejs-server/tsconfig.json b/examples/threejs-server/tsconfig.json index fc3c2101f..c98416d4b 100644 --- a/examples/threejs-server/tsconfig.json +++ b/examples/threejs-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/threejs-server/tsconfig.server.json b/examples/threejs-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/threejs-server/tsconfig.server.json +++ b/examples/threejs-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/transcript-server/package.json b/examples/transcript-server/package.json index dcba3d7c0..0ba3293f1 100644 --- a/examples/transcript-server/package.json +++ b/examples/transcript-server/package.json @@ -37,7 +37,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/transcript-server/tsconfig.json b/examples/transcript-server/tsconfig.json index 535267b25..a7cd29561 100644 --- a/examples/transcript-server/tsconfig.json +++ b/examples/transcript-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client", "dom-speech-recognition"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/transcript-server/tsconfig.server.json b/examples/transcript-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/transcript-server/tsconfig.server.json +++ b/examples/transcript-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/video-resource-server/package.json b/examples/video-resource-server/package.json index b0d04aff1..f81231ab8 100644 --- a/examples/video-resource-server/package.json +++ b/examples/video-resource-server/package.json @@ -36,7 +36,7 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/video-resource-server/tsconfig.json b/examples/video-resource-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/video-resource-server/tsconfig.json +++ b/examples/video-resource-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/video-resource-server/tsconfig.server.json b/examples/video-resource-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/video-resource-server/tsconfig.server.json +++ b/examples/video-resource-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/examples/wiki-explorer-server/package.json b/examples/wiki-explorer-server/package.json index fe511ad0f..5158af0d8 100644 --- a/examples/wiki-explorer-server/package.json +++ b/examples/wiki-explorer-server/package.json @@ -40,7 +40,7 @@ "concurrently": "^9.2.1", "cross-env": "^10.1.0", "force-graph": "^1.49.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" }, diff --git a/examples/wiki-explorer-server/tsconfig.json b/examples/wiki-explorer-server/tsconfig.json index 535267b25..d72e20451 100644 --- a/examples/wiki-explorer-server/tsconfig.json +++ b/examples/wiki-explorer-server/tsconfig.json @@ -4,6 +4,7 @@ "lib": ["ESNext", "DOM", "DOM.Iterable"], "module": "ESNext", "moduleResolution": "bundler", + "types": ["node", "vite/client"], "allowImportingTsExtensions": true, "resolveJsonModule": true, "isolatedModules": true, diff --git a/examples/wiki-explorer-server/tsconfig.server.json b/examples/wiki-explorer-server/tsconfig.server.json index 05ddd8ec4..9c5e058e8 100644 --- a/examples/wiki-explorer-server/tsconfig.server.json +++ b/examples/wiki-explorer-server/tsconfig.server.json @@ -4,6 +4,7 @@ "lib": ["ES2022"], "module": "NodeNext", "moduleResolution": "NodeNext", + "types": ["node"], "declaration": true, "emitDeclarationOnly": true, "outDir": "./dist", diff --git a/package-lock.json b/package-lock.json index 29e905875..230c7954d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -22,6 +22,7 @@ "@types/node": "20.19.27", "@types/react": "^19.2.2", "@types/react-dom": "^19.2.2", + "@typescript/native": "npm:typescript@^7.0.2", "bun": "^1.2.21", "caniuse-lite": "1.0.30001763", "cheerio": "1.1.2", @@ -84,28 +85,46 @@ "cors": "^2.8.5", "express": "^5.1.0", "prettier": "^3.6.2", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/basic-host/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/basic-host/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/basic-host/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/basic-server-preact": { "name": "@modelcontextprotocol/server-basic-preact", "version": "1.7.4", @@ -128,28 +147,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/basic-server-preact/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/basic-server-preact/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/basic-server-preact/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/basic-server-react": { "name": "@modelcontextprotocol/server-basic-react", "version": "1.7.4", @@ -175,28 +212,46 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/basic-server-react/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/basic-server-react/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/basic-server-react/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/basic-server-solid": { "name": "@modelcontextprotocol/server-basic-solid", "version": "1.7.4", @@ -218,29 +273,47 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0", "vite-plugin-solid": "^2.11.12" } }, - "examples/basic-server-solid/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/basic-server-solid/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/basic-server-solid/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/basic-server-svelte": { "name": "@modelcontextprotocol/server-basic-svelte", "version": "1.7.4", @@ -263,28 +336,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/basic-server-svelte/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/basic-server-svelte/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/basic-server-svelte/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/basic-server-vanillajs": { "name": "@modelcontextprotocol/server-basic-vanillajs", "version": "1.7.4", @@ -305,28 +396,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/basic-server-vanillajs/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/basic-server-vanillajs/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/basic-server-vanillajs/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/basic-server-vue": { "name": "@modelcontextprotocol/server-basic-vue", "version": "1.7.4", @@ -349,28 +458,46 @@ "@vitejs/plugin-vue": "^5.0.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/basic-server-vue/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/basic-server-vue/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/basic-server-vue/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/budget-allocator-server": { "name": "@modelcontextprotocol/server-budget-allocator", "version": "1.7.4", @@ -392,28 +519,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/budget-allocator-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/budget-allocator-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/budget-allocator-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/cohort-heatmap-server": { "name": "@modelcontextprotocol/server-cohort-heatmap", "version": "1.7.4", @@ -439,28 +584,46 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/cohort-heatmap-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/cohort-heatmap-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/cohort-heatmap-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/customer-segmentation-server": { "name": "@modelcontextprotocol/server-customer-segmentation", "version": "1.7.4", @@ -482,28 +645,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/customer-segmentation-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/customer-segmentation-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/customer-segmentation-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/debug-server": { "name": "@modelcontextprotocol/server-debug", "version": "1.7.4", @@ -524,28 +705,46 @@ "cors": "^2.8.5", "cross-env": "^10.1.0", "express": "^5.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/debug-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/debug-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/debug-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/integration-server": { "version": "1.7.4", "dependencies": { @@ -568,28 +767,46 @@ "@types/react-dom": "^19.2.2", "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/integration-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/integration-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/integration-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/lazy-auth-server": { "name": "@modelcontextprotocol/server-lazy-auth", "version": "1.7.4", @@ -610,28 +827,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/lazy-auth-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/lazy-auth-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/lazy-auth-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/map-server": { "name": "@modelcontextprotocol/server-map", "version": "1.7.4", @@ -652,28 +887,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/map-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/map-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/map-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/pdf-server": { "name": "@modelcontextprotocol/server-pdf", "version": "1.7.4", @@ -696,28 +949,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/pdf-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/pdf-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/pdf-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/qr-server": { "name": "@modelcontextprotocol/server-qr", "version": "1.7.4", @@ -743,19 +1014,44 @@ "concurrently": "^9.2.1", "cross-env": "^10.1.0", "tsx": "^4.21.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/quickstart/node_modules/@types/node": { - "version": "22.19.5", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.19.5.tgz", - "integrity": "sha512-HfF8+mYcHPcPypui3w3mvzuIErlNOh2OAG+BCeBZCEwyiD5ls2SiCwEyT47OELtf7M3nHxBdu0FsmzdKxkN52Q==", + "examples/quickstart/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.21.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, "examples/say-server": { @@ -793,28 +1089,46 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/scenario-modeler-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/scenario-modeler-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/scenario-modeler-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/shadertoy-server": { "name": "@modelcontextprotocol/server-shadertoy", "version": "1.7.4", @@ -835,28 +1149,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/shadertoy-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/shadertoy-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/shadertoy-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/sheet-music-server": { "name": "@modelcontextprotocol/server-sheet-music", "version": "1.7.4", @@ -878,28 +1210,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/sheet-music-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/sheet-music-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/sheet-music-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/system-monitor-server": { "name": "@modelcontextprotocol/server-system-monitor", "version": "1.7.4", @@ -922,28 +1272,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/system-monitor-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/system-monitor-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/system-monitor-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/threejs-server": { "name": "@modelcontextprotocol/server-threejs", "version": "1.7.4", @@ -971,28 +1339,46 @@ "@vitejs/plugin-react": "^4.3.4", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/threejs-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/threejs-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/threejs-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/transcript-server": { "name": "@modelcontextprotocol/server-transcript", "version": "1.7.4", @@ -1014,28 +1400,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/transcript-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/transcript-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/transcript-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/video-resource-server": { "name": "@modelcontextprotocol/server-video-resource", "version": "1.7.4", @@ -1056,28 +1460,46 @@ "@types/node": "22.10.0", "concurrently": "^9.2.1", "cross-env": "^10.1.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/video-resource-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/video-resource-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/video-resource-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "examples/wiki-explorer-server": { "name": "@modelcontextprotocol/server-wiki-explorer", "version": "1.7.4", @@ -1100,28 +1522,46 @@ "concurrently": "^9.2.1", "cross-env": "^10.1.0", "force-graph": "^1.49.0", - "typescript": "^5.9.3", + "typescript": "^7.0.2", "vite": "^6.0.0", "vite-plugin-singlefile": "^2.3.0" } }, - "examples/wiki-explorer-server/node_modules/@types/node": { - "version": "22.10.0", - "resolved": "https://registry.npmjs.org/@types/node/-/node-22.10.0.tgz", - "integrity": "sha512-XC70cRZVElFHfIUB40FgZOBbgJYFKKMa5nb9lxcwYstFG/Mi+/Y0bGS+rs6Dmhmkpq4pnNiLiuZAbc02YCOnmA==", + "examples/wiki-explorer-server/node_modules/typescript": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", "dev": true, - "license": "MIT", - "dependencies": { - "undici-types": "~6.20.0" + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" } }, - "examples/wiki-explorer-server/node_modules/undici-types": { - "version": "6.20.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz", - "integrity": "sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==", - "dev": true, - "license": "MIT" - }, "node_modules/@babel/code-frame": { "version": "7.28.6", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.28.6.tgz", @@ -4047,6 +4487,382 @@ "dev": true, "license": "MIT" }, + "node_modules/@typescript/native": { + "name": "typescript", + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-7.0.2.tgz", + "integrity": "sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc" + }, + "engines": { + "node": ">=16.20.0" + }, + "optionalDependencies": { + "@typescript/typescript-aix-ppc64": "7.0.2", + "@typescript/typescript-darwin-arm64": "7.0.2", + "@typescript/typescript-darwin-x64": "7.0.2", + "@typescript/typescript-freebsd-arm64": "7.0.2", + "@typescript/typescript-freebsd-x64": "7.0.2", + "@typescript/typescript-linux-arm": "7.0.2", + "@typescript/typescript-linux-arm64": "7.0.2", + "@typescript/typescript-linux-loong64": "7.0.2", + "@typescript/typescript-linux-mips64el": "7.0.2", + "@typescript/typescript-linux-ppc64": "7.0.2", + "@typescript/typescript-linux-riscv64": "7.0.2", + "@typescript/typescript-linux-s390x": "7.0.2", + "@typescript/typescript-linux-x64": "7.0.2", + "@typescript/typescript-netbsd-arm64": "7.0.2", + "@typescript/typescript-netbsd-x64": "7.0.2", + "@typescript/typescript-openbsd-arm64": "7.0.2", + "@typescript/typescript-openbsd-x64": "7.0.2", + "@typescript/typescript-sunos-x64": "7.0.2", + "@typescript/typescript-win32-arm64": "7.0.2", + "@typescript/typescript-win32-x64": "7.0.2" + } + }, + "node_modules/@typescript/typescript-aix-ppc64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-aix-ppc64/-/typescript-aix-ppc64-7.0.2.tgz", + "integrity": "sha512-MTKKkWB7p/0E9xi1d1tHtZ5PiLkGEMIq88pK2CubZjOsLtYTLqhgIgi6zepFa+9GHZ6h05NMCkQxGKiPXMxXtQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-darwin-arm64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-darwin-arm64/-/typescript-darwin-arm64-7.0.2.tgz", + "integrity": "sha512-gowzar9MwS/aRWp6f3a4KUqzRjAZjOsmGNCM6LcTgXum+dBfgsBVMN+AgvOCCbguXyick6LJhpBszxMebJ8syA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-darwin-x64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-darwin-x64/-/typescript-darwin-x64-7.0.2.tgz", + "integrity": "sha512-SZ9xZInqApNlNGc9s0W1VSsktYSOe9cFqNOIqmN1Gs8SmkjKZYFt017G4VwPxASInODuAdbTW7sXiFUf893RgA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-freebsd-arm64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-freebsd-arm64/-/typescript-freebsd-arm64-7.0.2.tgz", + "integrity": "sha512-W5NH4y/J0plIIS5b2xvTEkU7JFxyqdMAOgf+Ilhl0vHQXKO5dZoxd+C/jEtq56c4F3wk71RB4BMRQ2XdI+bwYQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-freebsd-x64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-freebsd-x64/-/typescript-freebsd-x64-7.0.2.tgz", + "integrity": "sha512-UMGDx5sTpzNw3WiPebH7l90IWfJggEd+egHt/q6p7/Cm3zqoV7VxkGXt+3DxPIw8CcmvAB0j3sVVfbhX+M4Tpw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-arm": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-arm/-/typescript-linux-arm-7.0.2.tgz", + "integrity": "sha512-gffT3xPz9sR7j/YJExkyPntrI0P2EP9XbOyWzth2/Gs0RstK+90RBcO0ncXoXy/beYll1SXw846Nf2zdnEz0QQ==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-arm64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-arm64/-/typescript-linux-arm64-7.0.2.tgz", + "integrity": "sha512-Qh4eU4/y3yDjnfjjyPYihMj5/ODIlmt+Bzu17OI+fiSRDW57QmU5SiN63exPRNJPKUzcc1INa1NXdrJ+MqHjUQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-loong64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-loong64/-/typescript-linux-loong64-7.0.2.tgz", + "integrity": "sha512-uEHck9i8hoAzXPiYRib1O7miOnz23SxIeVl6F4LXox+qov1K35jHcEW6VHKvZI+pyvl7fZEP4MCU5LYvIq1GuQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-mips64el": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-mips64el/-/typescript-linux-mips64el-7.0.2.tgz", + "integrity": "sha512-R4KvAMnE43W5Qeqb0Ly56O3mWMWIAgsMyz36DCaycd5nbg/9kzm0liw3JocfRqyJY0KPmzFjbswozXyW0DnIYA==", + "cpu": [ + "mips64el" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-ppc64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-ppc64/-/typescript-linux-ppc64-7.0.2.tgz", + "integrity": "sha512-DORx5b3sd/4S7eayxm4FQv+A7CrkUIGRaHiwI8oiHTAI1fAPWhF4J0vAlkC8biAlHSVVwxMQ3tjZ2/DVbnQiiA==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-riscv64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-riscv64/-/typescript-linux-riscv64-7.0.2.tgz", + "integrity": "sha512-wf0jqEDOjrPRnKwYRyyJDRo11KMbvMFrU+q4zqKyChODBzvlkbhNQfKvLxQCcwTpdDaXSHZTVuh0JoCrKCUMHQ==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-s390x": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-s390x/-/typescript-linux-s390x-7.0.2.tgz", + "integrity": "sha512-IkwJc3L7yhytWd/ewjyxNDfOmswCm9GWMJT/ue/dU4aZNbwZeYAetq42VyLmsmSjvoX7z74X6ZaYCtzAr0EuGw==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-linux-x64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-linux-x64/-/typescript-linux-x64-7.0.2.tgz", + "integrity": "sha512-EYdf2cNg7rgCWJnxCdJ+F3V39O8ihb37eHAu1LK8oAFizgTQbPOK7zHHXbPt8rX24COqODXeI3sIf0fCXG7H/A==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-netbsd-arm64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-netbsd-arm64/-/typescript-netbsd-arm64-7.0.2.tgz", + "integrity": "sha512-+polYF4MF04aPpO5FTkHran9yUQDSXqy5GiSDKpsll5jy3l3+g9QLhpf39T+ePtefhXLOGrLl0QIjkQP6VnelA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-netbsd-x64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-netbsd-x64/-/typescript-netbsd-x64-7.0.2.tgz", + "integrity": "sha512-8YIT0EHM/3dq10ZOVF/A7pc/YSMtbcecct4rWtexrnSCHOPcpC2KTLXfTCR6vDpnSiY12heNb1GiN/wu+T/FyA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-openbsd-arm64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-openbsd-arm64/-/typescript-openbsd-arm64-7.0.2.tgz", + "integrity": "sha512-APT8+ClYnuYm1u9+kgGXoMj2VzWzcymwh2gNSQVySHfkRDGOTVkoWLjCmOQSaO+PoqQ57B0flRp9SA+7GnnkzQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-openbsd-x64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-openbsd-x64/-/typescript-openbsd-x64-7.0.2.tgz", + "integrity": "sha512-yX7s+Q0Dln0Dt9tEzZsAjXXR/+ytBM7AlglaqyeMPxQszJ1JhlJdZ6jLA+IzldHtflX81em7lDao1xXu+aRRkg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-sunos-x64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-sunos-x64/-/typescript-sunos-x64-7.0.2.tgz", + "integrity": "sha512-dLJDGaLZ1D4HPQn62u1n8mBDkJREwMsAkCdkwd4Ieqw+x3TUyTsqY0YiBCtE6H6OzzgGk3iuZ3vFWRS+E8/d1g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-win32-arm64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-win32-arm64/-/typescript-win32-arm64-7.0.2.tgz", + "integrity": "sha512-Gyl1Vy6OsWesLzmq+EP0Fb7b4Nid5232AvcA2SFcdYreldpNtYFFofPjnt62y9hQy7VTaZp65ICJjuAQRaVcIQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=16.20.0" + } + }, + "node_modules/@typescript/typescript-win32-x64": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/@typescript/typescript-win32-x64/-/typescript-win32-x64-7.0.2.tgz", + "integrity": "sha512-0BQ3HkAHHlKLSp1qRvf3SUhGpGsDuhB/jgFw75guyqbxJqEaS0Cw/VFO8i2nHglJUzQCRtMMR/IBAKE3ETMC4g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "Apache-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=16.20.0" + } + }, "node_modules/@typescript/vfs": { "version": "1.6.2", "resolved": "https://registry.npmjs.org/@typescript/vfs/-/vfs-1.6.2.tgz", diff --git a/package.json b/package.json index 8c6ead57b..816cf1228 100644 --- a/package.json +++ b/package.json @@ -48,9 +48,10 @@ ], "scripts": { "start": "npm run examples:dev", - "generate:schemas": "tsx scripts/generate-schemas.ts && prettier --write \"src/generated/**/*\"", + "generate:schemas": "node --import tsx scripts/generate-schemas.ts && prettier --write \"src/generated/**/*\"", "sync:snippets": "bun scripts/sync-snippets.ts", - "build": "npm run generate:schemas && npm run sync:snippets && node scripts/run-bun.mjs build.bun.ts && node scripts/link-self.mjs", + "build": "npm run generate:schemas && npm run sync:snippets && npm run typecheck:native && node --import tsx scripts/run-bun.ts build.bun.ts && node --import tsx scripts/link-self.ts", + "typecheck:native": "node node_modules/@typescript/native/bin/tsc --noEmit --project tsconfig.native.json", "prepack": "npm run build", "build:all": "npm run examples:build", "test": "bun test src examples", @@ -62,16 +63,17 @@ "preexamples:build": "npm run build", "examples:build": "bun examples/run-all.ts build", "examples:start": "NODE_ENV=development npm run build && bun examples/run-all.ts start", + "examples:start:e2e": "NODE_ENV=development npm run build && bun examples/run-all.ts build && bun examples/run-all.ts serve", "examples:dev": "NODE_ENV=development bun examples/run-all.ts dev", "watch": "nodemon --watch src --ext ts,tsx --exec 'bun build.bun.ts'", "prepare": "npm run build && husky", - "docs": "typedoc", - "docs:watch": "typedoc --watch", + "docs": "node --import tsx node_modules/typedoc/bin/typedoc --options typedoc.config.ts", + "docs:watch": "node --import tsx node_modules/typedoc/bin/typedoc --options typedoc.config.ts --watch", "generate:screenshots": "npm run build:all && docker run --rm -e EXAMPLE -e GENERATE_SCREENSHOTS=1 -v $(pwd):/work -w /work mcr.microsoft.com/playwright:v1.57.0-noble sh -c 'apt-get update -qq && apt-get install -qq -y python3-venv curl > /dev/null && curl -LsSf https://astral.sh/uv/install.sh | sh && export PATH=\"$HOME/.local/bin:$PATH\" && npm i -g bun && npm ci && npx playwright test tests/e2e/generate-grid-screenshots.spec.ts'", "prettier": "prettier -u \"**/*.{js,jsx,ts,tsx,mjs,json,md,yml,yaml}\" --check", "prettier:fix": "prettier -u \"**/*.{js,jsx,ts,tsx,mjs,json,md,yml,yaml}\" --write", - "check:versions": "node scripts/check-versions.mjs", - "bump": "node scripts/bump-version.mjs", + "check:versions": "node --import tsx scripts/check-versions.ts", + "bump": "node --import tsx scripts/bump-version.ts", "update-lock:docker": "rm -rf node_modules package-lock.json examples/*/node_modules && docker run --rm --platform linux/amd64 -v $(pwd):/work -w /work -e HOME=/tmp node:latest npm i --registry=https://registry.npmjs.org/ --ignore-scripts && rm -rf node_modules examples/*/node_modules && npm i --registry=https://registry.npmjs.org/" }, "author": "Olivier Chafik", @@ -104,6 +106,7 @@ "tsx": "^4.21.0", "typedoc": "^0.28.14", "typedoc-github-theme": "^0.4.0", + "@typescript/native": "npm:typescript@^7.0.2", "typescript": "^5.9.3", "zod": "^4.1.13" }, diff --git a/playwright.config.ts b/playwright.config.ts index ecf1e136a..a9ec2622e 100644 --- a/playwright.config.ts +++ b/playwright.config.ts @@ -1,5 +1,10 @@ import { defineConfig, devices } from "@playwright/test"; +const hostPort = process.env.E2E_HOST_PORT ?? "8080"; +const sandboxPort = process.env.E2E_SANDBOX_PORT ?? "8081"; +const baseURL = `http://localhost:${hostPort}`; +const webServerTimeout = Number(process.env.E2E_WEB_SERVER_TIMEOUT ?? "180000"); + export default defineConfig({ testDir: "./tests/e2e", // Exclude the screenshot generation spec from default runs. @@ -19,7 +24,7 @@ export default defineConfig({ snapshotPathTemplate: "{testDir}/{testFileDir}/{testFileName}-snapshots/{arg}{ext}", use: { - baseURL: "http://localhost:8080", + baseURL, trace: "on-first-retry", screenshot: "only-on-failure", }, @@ -37,16 +42,20 @@ export default defineConfig({ // Run examples server before tests // Supports EXAMPLE= env var to run a single example (e.g., EXAMPLE=say-server npm run test:e2e) webServer: { - command: "npm run examples:start", - url: "http://localhost:8080", + command: "npm run examples:start:e2e", + url: baseURL, // Always start fresh servers to avoid stale state issues reuseExistingServer: false, // 3 minutes to allow uv to download Python dependencies on first run - timeout: 180000, + timeout: webServerTimeout, // Pass through EXAMPLE env var to filter to a single server env: { ...process.env, EXAMPLE: process.env.EXAMPLE ?? "", + EXCLUDE_EXAMPLES: process.env.E2E_EXCLUDE_EXAMPLES ?? "", + HOST_PORT: hostPort, + SANDBOX_PORT: sandboxPort, + VITE_SANDBOX_PORT: sandboxPort, // Let pdf-server fetch from the http://127.0.0.1 range-counting fixture // (validateUrl rejects loopback HTTP unless this is set). Scoped to this // server's check only — does not touch Node's TLS verification. diff --git a/scripts/bump-version.mjs b/scripts/bump-version.ts similarity index 76% rename from scripts/bump-version.mjs rename to scripts/bump-version.ts index 65c878fd5..4d53c635d 100644 --- a/scripts/bump-version.mjs +++ b/scripts/bump-version.ts @@ -4,11 +4,11 @@ * to the same version. * * Usage: - * node scripts/bump-version.mjs patch - * node scripts/bump-version.mjs minor - * node scripts/bump-version.mjs major - * node scripts/bump-version.mjs 1.4.0 - * node scripts/bump-version.mjs prerelease --preid=beta + * node scripts/bump-version.ts patch + * node scripts/bump-version.ts minor + * node scripts/bump-version.ts major + * node scripts/bump-version.ts 1.4.0 + * node scripts/bump-version.ts prerelease --preid=beta * * Writes the new version to stdout (logs go to stderr). */ @@ -19,12 +19,12 @@ import { readFileSync } from "node:fs"; const args = process.argv.slice(2); if (!args[0]) { console.error( - "Usage: node scripts/bump-version.mjs [--preid=]", + "Usage: node scripts/bump-version.ts [--preid=]", ); process.exit(1); } -const exec = (cmd) => +const exec = (cmd: string) => execSync(cmd, { stdio: ["inherit", "pipe", "inherit"] }) .toString() .trim(); diff --git a/scripts/check-versions.mjs b/scripts/check-versions.ts similarity index 98% rename from scripts/check-versions.mjs rename to scripts/check-versions.ts index 0d0453f47..27bf1f5e8 100644 --- a/scripts/check-versions.mjs +++ b/scripts/check-versions.ts @@ -23,7 +23,7 @@ const [major, minor] = rootVersion.split(".").map(Number); * - "^X.Y.Z" where X.Y matches root major.minor (e.g., ^1.0.0 is compatible with 1.0.1) * - Exact match like "1.0.1" */ -function isCompatible(dep) { +function isCompatible(dep: string) { if (dep === "../..") return true; // Handle caret ranges like ^1.0.0 diff --git a/scripts/link-self.mjs b/scripts/link-self.ts similarity index 100% rename from scripts/link-self.mjs rename to scripts/link-self.ts diff --git a/scripts/run-bun.mjs b/scripts/run-bun.ts similarity index 100% rename from scripts/run-bun.mjs rename to scripts/run-bun.ts diff --git a/scripts/typedoc-plugin-fix-mermaid-entities.mjs b/scripts/typedoc-plugin-fix-mermaid-entities.ts similarity index 95% rename from scripts/typedoc-plugin-fix-mermaid-entities.mjs rename to scripts/typedoc-plugin-fix-mermaid-entities.ts index c663aca92..d4ad8abf7 100644 --- a/scripts/typedoc-plugin-fix-mermaid-entities.mjs +++ b/scripts/typedoc-plugin-fix-mermaid-entities.ts @@ -12,14 +12,14 @@ * CSS filters handle dark mode styling. */ -import { Renderer } from "typedoc"; +import { Renderer, type Application } from "typedoc"; /** * Decode HTML entities back to raw characters. * @param {string} html - HTML-encoded string * @returns {string} Decoded string */ -function decodeHtmlEntities(html) { +function decodeHtmlEntities(html: string) { return html .replace(/&#(\d+);/g, (_, num) => String.fromCharCode(parseInt(num, 10))) .replace(/&#x([0-9a-fA-F]+);/g, (_, hex) => @@ -48,7 +48,7 @@ const darkModeStyles = ` * TypeDoc plugin entry point. * @param {import('typedoc').Application} app */ -export function load(app) { +export function load(app: Application) { // Use high priority (200) to run before the mermaid plugin (default is 0) app.renderer.on( Renderer.EVENT_END_PAGE, diff --git a/scripts/typedoc-plugin-mcpstyle.mjs b/scripts/typedoc-plugin-mcpstyle.ts similarity index 90% rename from scripts/typedoc-plugin-mcpstyle.mjs rename to scripts/typedoc-plugin-mcpstyle.ts index aea65bc5f..ec1a08090 100644 --- a/scripts/typedoc-plugin-mcpstyle.mjs +++ b/scripts/typedoc-plugin-mcpstyle.ts @@ -9,13 +9,13 @@ * OS prefers-color-scheme media query */ -import { Renderer } from "typedoc"; +import { Renderer, type Application } from "typedoc"; /** * TypeDoc plugin entry point. * @param {import('typedoc').Application} app */ -export function load(app) { +export function load(app: Application) { app.renderer.on(Renderer.EVENT_END_PAGE, (page) => { if (!page.contents) return; @@ -33,8 +33,12 @@ export function load(app) { // For document pages, replace the breadcrumb with the group name // (e.g. "Security", "Getting Started"). The page title is in the H1. - if (page.model?.isDocument?.() && page.model.frontmatter?.group) { - const group = String(page.model.frontmatter.group); + const documentModel = page.model as { + isDocument?: () => boolean; + frontmatter?: Record; + }; + if (documentModel?.isDocument?.() && documentModel.frontmatter?.group) { + const group = String(documentModel.frontmatter.group); page.contents = page.contents.replace( /
    ]*>.*?<\/ul>/, `
    • ${group}
    `, diff --git a/scripts/typedoc-plugin-seo.mjs b/scripts/typedoc-plugin-seo.ts similarity index 90% rename from scripts/typedoc-plugin-seo.mjs rename to scripts/typedoc-plugin-seo.ts index 11677e6ae..e44e1ec09 100644 --- a/scripts/typedoc-plugin-seo.mjs +++ b/scripts/typedoc-plugin-seo.ts @@ -7,13 +7,20 @@ * - Copies favicons to the output directory */ -import { Renderer } from "typedoc"; +import { Renderer, type Application } from "typedoc"; import fs from "node:fs"; import path from "node:path"; import zlib from "node:zlib"; import * as htmlparser2 from "htmlparser2"; const SITE_NAME = "MCP Apps"; +type Replacement = { old: string; new: string }; +type JsonLdOptions = { + title: string; + description: string; + url: string; + isDocument: boolean; +}; /** * Convert a TypeDoc-generated document filename to a lowercase hyphenated slug. @@ -22,7 +29,7 @@ const SITE_NAME = "MCP Apps"; * @param {string} filename * @returns {string} */ -function toSlug(filename) { +function toSlug(filename: string) { return filename .replace(/\.html$/, "") .replace(/_/g, "-") @@ -36,7 +43,7 @@ function toSlug(filename) { * @param {string} html * @returns {string} */ -function extractDescription(html) { +function extractDescription(html: string) { // Find the main content area const contentMatch = html.match( /
    ([\s\S]*?)<\/div>\s*<\/div>/, @@ -71,7 +78,7 @@ function extractDescription(html) { * @param {string} html * @returns {string} */ -function extractTitle(html) { +function extractTitle(html: string) { const match = html.match(/([^<]+)<\/title>/); return match ? match[1] : SITE_NAME; } @@ -81,7 +88,7 @@ function extractTitle(html) { * @param {string} url * @returns {boolean} */ -function isDocumentPage(url) { +function isDocumentPage(url: string) { return url.includes("documents/"); } @@ -94,7 +101,7 @@ function isDocumentPage(url) { * @param {boolean} options.isDocument * @returns {object} */ -function buildJsonLd({ title, description, url, isDocument }) { +function buildJsonLd({ title, description, url, isDocument }: JsonLdOptions) { return { "@context": "https://schema.org", "@type": isDocument ? "TechArticle" : "WebPage", @@ -114,7 +121,7 @@ function buildJsonLd({ title, description, url, isDocument }) { * TypeDoc plugin entry point. * @param {import('typedoc').Application} app */ -export function load(app) { +export function load(app: Application) { const hostedBaseUrl = app.options.getValue("hostedBaseUrl") || ""; // --- Per-page: inject JSON-LD, meta descriptions, and favicons --- @@ -124,9 +131,13 @@ export function load(app) { const title = extractTitle(page.contents); // Prefer frontmatter description, fall back to auto-extraction + const documentModel = page.model as { + isDocument?: () => boolean; + frontmatter?: Record<string, unknown>; + }; const frontmatterDesc = - page.model?.isDocument?.() && page.model.frontmatter?.description - ? String(page.model.frontmatter.description) + documentModel?.isDocument?.() && documentModel.frontmatter?.description + ? String(documentModel.frontmatter.description) : ""; const description = frontmatterDesc || extractDescription(page.contents); const fullUrl = hostedBaseUrl @@ -202,7 +213,7 @@ export function load(app) { if (!fs.existsSync(docsDir)) return; // Build rename map: old filename → new slug - const renameMap = new Map(); + const renameMap = new Map<string, string>(); for (const file of fs.readdirSync(docsDir)) { if (!file.endsWith(".html")) continue; const slug = toSlug(file); @@ -258,7 +269,11 @@ export function load(app) { * @param {string} varName - JS variable name (e.g. "navigationData", "searchData") * @param {Array<{old: string, new: string}>} replacements */ -function updateCompressedJsData(filePath, varName, replacements) { +function updateCompressedJsData( + filePath: string, + varName: string, + replacements: Replacement[], +) { if (!fs.existsSync(filePath)) return; let content = fs.readFileSync(filePath, "utf8"); @@ -293,7 +308,7 @@ function updateCompressedJsData(filePath, varName, replacements) { * @param {string} dir * @param {Array<{old: string, new: string}>} replacements */ -function updateLinksRecursive(dir, replacements) { +function updateLinksRecursive(dir: string, replacements: Replacement[]) { for (const entry of fs.readdirSync(dir, { withFileTypes: true })) { const fullPath = path.join(dir, entry.name); if (entry.isDirectory()) { diff --git a/tests/e2e/pdf-incremental-load.spec.ts b/tests/e2e/pdf-incremental-load.spec.ts index 52a99ee9a..02d068a8d 100644 --- a/tests/e2e/pdf-incremental-load.spec.ts +++ b/tests/e2e/pdf-incremental-load.spec.ts @@ -101,12 +101,19 @@ test.describe("PDF Server — incremental loading", () => { page, }) => { const fileSize = rangeServer.fileSizes["/noforms.pdf"]; - await displayPdf(page, `${rangeServer.baseUrl}/noforms.pdf`); + // Stall below the assertion threshold so a fast viewer cannot race ahead + // and add its own range fetches before server-side usage is measured. + const serverBudget = Math.floor(fileSize * 0.29); + await displayPdf( + page, + `${rangeServer.baseUrl}/noforms.pdf?stallAfterBytes=${serverBudget}`, + ); // Measure before the viewer iframe loads so the count reflects only the // server-side display_pdf range fetches. expect(rangeServer.stats().totalBytesServed).toBeLessThan(fileSize * 0.3); + rangeServer.release(); await waitForAppLoad(page); const sc = await readStructuredContent(page); expect(sc.formFields).toBeUndefined(); @@ -148,8 +155,10 @@ test.describe("PDF Server — incremental loading", () => { // display_pdf bails at the empty getFieldObjects() check before touching // the image stream, so this test does not exercise it.) await waitForFirstPageRendered(page); + // Exact stall-budget truncation avoids range-response overshoot, so the + // image-backed second page can render without crossing the older 90% mark. expect(rangeServer.stats().totalBytesServed).toBeGreaterThan( - fileSize * 0.9, + fileSize * 0.85, ); }); }); diff --git a/tests/helpers/range-counting-server.ts b/tests/helpers/range-counting-server.ts index 6f0dcd7f3..4ebea40ad 100644 --- a/tests/helpers/range-counting-server.ts +++ b/tests/helpers/range-counting-server.ts @@ -194,12 +194,16 @@ export async function startRangeServer(): Promise<RangeServer> { } } - // Stall once N bytes have already been served — lets pdfjs read the + // Stall at an exact aggregate byte budget — lets pdfjs read the // header/trailer/xref (scattered across the file) before blocking the - // bulk content streams. + // bulk content streams. Truncate the response that reaches the budget so + // one large range cannot overshoot it before the next request stalls. if (stallAfterBytes !== null) { - if (totalBytesServed >= parseInt(stallAfterBytes, 10)) { + const budget = parseInt(stallAfterBytes, 10); + if (totalBytesServed >= budget) { await releasePromise; + } else { + end = Math.min(end, begin + budget - totalBytesServed); } } diff --git a/tsconfig.native.json b/tsconfig.native.json new file mode 100644 index 000000000..9b2fe217b --- /dev/null +++ b/tsconfig.native.json @@ -0,0 +1,23 @@ +{ + "extends": "./tsconfig.json", + "compilerOptions": { + "declaration": false, + "emitDeclarationOnly": false, + "noEmit": true, + "types": ["node", "bun"], + "lib": ["ES2021", "DOM"] + }, + "include": [ + "src/**/*.ts", + "src/**/*.tsx", + "docs/**/*.ts", + "docs/**/*.tsx", + "scripts/**/*.ts", + "build.bun.ts", + "typedoc.config.ts", + "examples/run-all.ts", + "examples/pdf-server/build-mcpb.ts", + "examples/basic-server-svelte/svelte.config.ts" + ], + "exclude": ["node_modules", "dist", "**/*.test.ts", "**/*.test.tsx"] +} diff --git a/typedoc.config.mjs b/typedoc.config.ts similarity index 86% rename from typedoc.config.mjs rename to typedoc.config.ts index 4c5baa320..f0a06b39f 100644 --- a/typedoc.config.mjs +++ b/typedoc.config.ts @@ -1,6 +1,5 @@ -import { OptionDefaults } from "typedoc"; +import { OptionDefaults, type TypeDocOptions } from "typedoc"; -/** @type {Partial<import('typedoc').TypeDocOptions>} */ const config = { name: "MCP Apps", readme: "README.md", @@ -49,9 +48,9 @@ const config = { out: "docs/api", plugin: [ "typedoc-github-theme", - "./scripts/typedoc-plugin-fix-mermaid-entities.mjs", - "./scripts/typedoc-plugin-seo.mjs", - "./scripts/typedoc-plugin-mcpstyle.mjs", + "./scripts/typedoc-plugin-fix-mermaid-entities.ts", + "./scripts/typedoc-plugin-seo.ts", + "./scripts/typedoc-plugin-mcpstyle.ts", "@boneskull/typedoc-plugin-mermaid", ], ignoredHighlightLanguages: ["mermaid"], @@ -61,6 +60,6 @@ const config = { kind_plural_module: "API Documentation", }, }, -}; +} satisfies Partial<TypeDocOptions>; export default config;