From 7a8703be63bc8aa4c4523ee84b870781cc5ce969 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Tue, 20 Jan 2026 15:20:48 +0100 Subject: [PATCH 01/62] wip --- packages/adapter-cloudflare/CHANGELOG.md | 254 -------------- packages/adapter-cloudflare/README.md | 213 ----------- packages/adapter-cloudflare/package.json | 36 -- packages/adapter-cloudflare/src/index.ts | 0 packages/adapter-cloudflare/src/plugin.ts | 68 ---- packages/adapter-cloudflare/tsconfig.json | 9 - packages/adapter-cloudflare/tsdown.config.ts | 23 -- packages/adapter-cloudflare/virtual.d.ts | 3 - packages/adapter-netlify/CHANGELOG.md | 57 --- packages/adapter-netlify/index.ts | 0 packages/adapter-netlify/package.json | 31 -- packages/adapter-netlify/src/index.ts | 0 packages/adapter-netlify/src/plugin.ts | 54 --- packages/adapter-netlify/tsconfig.json | 9 - packages/adapter-netlify/tsdown.config.ts | 23 -- packages/adapter-vercel/CHANGELOG.md | 215 ------------ packages/adapter-vercel/README.md | 112 ------ packages/adapter-vercel/package.json | 63 ---- packages/adapter-vercel/src/api.ts | 95 ----- packages/adapter-vercel/src/assert.ts | 11 - packages/adapter-vercel/src/build.ts | 29 -- packages/adapter-vercel/src/config.ts | 82 ----- packages/adapter-vercel/src/helpers.ts | 16 - packages/adapter-vercel/src/index.ts | 0 .../src/photon/universal-middleware-dev.ts | 28 -- .../src/photon/universal-middleware-prod.ts | 15 - packages/adapter-vercel/src/plugins/api.ts | 58 --- packages/adapter-vercel/src/plugins/bundle.ts | 277 --------------- .../src/plugins/clean-outdir.ts | 43 --- packages/adapter-vercel/src/plugins/index.ts | 48 --- packages/adapter-vercel/src/plugins/loader.ts | 187 ---------- packages/adapter-vercel/src/plugins/routes.ts | 52 --- .../adapter-vercel/src/plugins/setupEnvs.ts | 268 -------------- packages/adapter-vercel/src/plugins/wasm.ts | 26 -- packages/adapter-vercel/src/types.ts | 119 ------- packages/adapter-vercel/src/utils/const.ts | 1 - .../adapter-vercel/src/utils/destination.ts | 13 - packages/adapter-vercel/src/utils/edge.ts | 1 - packages/adapter-vercel/src/utils/env.ts | 6 - packages/adapter-vercel/src/utils/external.ts | 3 - .../adapter-vercel/src/utils/fs-entries.ts | 92 ----- packages/adapter-vercel/src/utils/index.ts | 2 - .../src/utils/original-request.ts | 33 -- packages/adapter-vercel/src/utils/route.ts | 18 - packages/adapter-vercel/tsconfig.json | 16 - packages/adapter-vercel/tsdown.config.ts | 28 -- packages/core/src/api/api.ts | 59 ---- packages/core/src/apply.ts | 124 ------- .../core/src/plugin/plugins/commonConfig.ts | 155 -------- .../plugin/plugins/getMiddlewaresPlugin.ts | 108 ------ .../core/src/plugin/plugins/installPhoton.ts | 189 ---------- .../core/src/plugin/plugins/mirrorMeta.ts | 172 --------- .../core/src/plugin/plugins/photonEntry.ts | 332 ------------------ .../plugins/resolvePhotonConfigPlugin.ts | 74 ---- .../src/plugin/plugins/supportedServers.ts | 20 -- .../core/src/plugin/plugins/targetLoader.ts | 169 --------- packages/core/src/plugin/utils/entry.ts | 23 -- .../src/plugin/utils/escapeStringRegexp.ts | 4 - packages/core/src/plugin/utils/isBun.ts | 1 - packages/core/src/plugin/utils/isDeno.ts | 1 - packages/core/src/plugin/utils/logVite.ts | 7 - packages/core/src/plugin/utils/servers.ts | 19 - packages/core/src/plugin/utils/universal.ts | 20 -- packages/core/src/plugin/utils/virtual.ts | 100 ------ .../runtime/adapters/handleViteDevServer.ts | 20 -- packages/core/src/runtime/globalStore.ts | 7 - packages/core/src/utils/assert.ts | 83 ----- packages/core/src/utils/deferred.ts | 17 - packages/core/src/utils/meta.ts | 47 --- packages/core/src/validators/coerce.ts | 168 --------- packages/core/src/validators/types.ts | 17 - packages/core/src/validators/validators.ts | 118 ------- 72 files changed, 4791 deletions(-) delete mode 100644 packages/adapter-cloudflare/CHANGELOG.md delete mode 100644 packages/adapter-cloudflare/README.md delete mode 100644 packages/adapter-cloudflare/package.json delete mode 100644 packages/adapter-cloudflare/src/index.ts delete mode 100644 packages/adapter-cloudflare/src/plugin.ts delete mode 100644 packages/adapter-cloudflare/tsconfig.json delete mode 100644 packages/adapter-cloudflare/tsdown.config.ts delete mode 100644 packages/adapter-cloudflare/virtual.d.ts delete mode 100644 packages/adapter-netlify/CHANGELOG.md delete mode 100644 packages/adapter-netlify/index.ts delete mode 100644 packages/adapter-netlify/package.json delete mode 100644 packages/adapter-netlify/src/index.ts delete mode 100644 packages/adapter-netlify/src/plugin.ts delete mode 100644 packages/adapter-netlify/tsconfig.json delete mode 100644 packages/adapter-netlify/tsdown.config.ts delete mode 100644 packages/adapter-vercel/CHANGELOG.md delete mode 100644 packages/adapter-vercel/README.md delete mode 100644 packages/adapter-vercel/package.json delete mode 100644 packages/adapter-vercel/src/api.ts delete mode 100644 packages/adapter-vercel/src/assert.ts delete mode 100644 packages/adapter-vercel/src/build.ts delete mode 100644 packages/adapter-vercel/src/config.ts delete mode 100644 packages/adapter-vercel/src/helpers.ts delete mode 100644 packages/adapter-vercel/src/index.ts delete mode 100644 packages/adapter-vercel/src/photon/universal-middleware-dev.ts delete mode 100644 packages/adapter-vercel/src/photon/universal-middleware-prod.ts delete mode 100644 packages/adapter-vercel/src/plugins/api.ts delete mode 100644 packages/adapter-vercel/src/plugins/bundle.ts delete mode 100644 packages/adapter-vercel/src/plugins/clean-outdir.ts delete mode 100644 packages/adapter-vercel/src/plugins/index.ts delete mode 100644 packages/adapter-vercel/src/plugins/loader.ts delete mode 100644 packages/adapter-vercel/src/plugins/routes.ts delete mode 100644 packages/adapter-vercel/src/plugins/setupEnvs.ts delete mode 100644 packages/adapter-vercel/src/plugins/wasm.ts delete mode 100644 packages/adapter-vercel/src/types.ts delete mode 100644 packages/adapter-vercel/src/utils/const.ts delete mode 100644 packages/adapter-vercel/src/utils/destination.ts delete mode 100644 packages/adapter-vercel/src/utils/edge.ts delete mode 100644 packages/adapter-vercel/src/utils/env.ts delete mode 100644 packages/adapter-vercel/src/utils/external.ts delete mode 100644 packages/adapter-vercel/src/utils/fs-entries.ts delete mode 100644 packages/adapter-vercel/src/utils/index.ts delete mode 100644 packages/adapter-vercel/src/utils/original-request.ts delete mode 100644 packages/adapter-vercel/src/utils/route.ts delete mode 100644 packages/adapter-vercel/tsconfig.json delete mode 100644 packages/adapter-vercel/tsdown.config.ts delete mode 100644 packages/core/src/api/api.ts delete mode 100644 packages/core/src/apply.ts delete mode 100644 packages/core/src/plugin/plugins/commonConfig.ts delete mode 100644 packages/core/src/plugin/plugins/getMiddlewaresPlugin.ts delete mode 100644 packages/core/src/plugin/plugins/installPhoton.ts delete mode 100644 packages/core/src/plugin/plugins/mirrorMeta.ts delete mode 100644 packages/core/src/plugin/plugins/photonEntry.ts delete mode 100644 packages/core/src/plugin/plugins/resolvePhotonConfigPlugin.ts delete mode 100644 packages/core/src/plugin/plugins/supportedServers.ts delete mode 100644 packages/core/src/plugin/plugins/targetLoader.ts delete mode 100644 packages/core/src/plugin/utils/entry.ts delete mode 100644 packages/core/src/plugin/utils/escapeStringRegexp.ts delete mode 100644 packages/core/src/plugin/utils/isBun.ts delete mode 100644 packages/core/src/plugin/utils/isDeno.ts delete mode 100644 packages/core/src/plugin/utils/logVite.ts delete mode 100644 packages/core/src/plugin/utils/servers.ts delete mode 100644 packages/core/src/plugin/utils/universal.ts delete mode 100644 packages/core/src/plugin/utils/virtual.ts delete mode 100644 packages/core/src/runtime/adapters/handleViteDevServer.ts delete mode 100644 packages/core/src/runtime/globalStore.ts delete mode 100644 packages/core/src/utils/assert.ts delete mode 100644 packages/core/src/utils/deferred.ts delete mode 100644 packages/core/src/utils/meta.ts delete mode 100644 packages/core/src/validators/coerce.ts delete mode 100644 packages/core/src/validators/types.ts delete mode 100644 packages/core/src/validators/validators.ts diff --git a/packages/adapter-cloudflare/CHANGELOG.md b/packages/adapter-cloudflare/CHANGELOG.md deleted file mode 100644 index ab9b5ddd..00000000 --- a/packages/adapter-cloudflare/CHANGELOG.md +++ /dev/null @@ -1,254 +0,0 @@ -## 0.0.1 (2025-08-19) - -## 0.1.13 - -### Patch Changes - -- 9e4534b: fix: upgrade dependencies -- Updated dependencies [9e4534b] - - @photonjs/core@0.1.20 - -## 0.1.12 - -### Patch Changes - -- Updated dependencies [5fd9297] - - @photonjs/core@0.1.19 - -## 0.1.12-beta.0 - -### Patch Changes - -- Updated dependencies [5fd9297] - - @photonjs/core@0.1.19-beta.0 - -## 0.1.11 - -### Patch Changes - -- 8815d51: stable release -- Updated dependencies [8815d51] - - @photonjs/core@0.1.16 - -## 0.1.10 - -### Patch Changes - -- 525d541: feat: better compatibility with Bun and Deno -- Updated dependencies [525d541] -- Updated dependencies [c3b669a] - - @photonjs/core@0.1.15 - -## 0.1.10-beta.0 - -### Patch Changes - -- 525d541: feat: better compatibility with Bun and Deno -- Updated dependencies [525d541] -- Updated dependencies [c3b669a] - - @photonjs/core@0.1.15-beta.0 - -## 0.1.9 - -### Patch Changes - -- 668c4f7: fix: upgrade dependencies -- Updated dependencies [668c4f7] - - @photonjs/core@0.1.14 - -## 0.1.8 - -### Patch Changes - -- 0d3faed: feat(hmr): do not forward HMR WS requests through photon server -- 0d3faed: feat: support `{ fetch }` entries -- 0d3faed: feat: HMR support for Deno and Bun -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] - - @photonjs/core@0.1.9 - -## 0.1.7 - -### Patch Changes - -- 230ab19: revert: fix: remove static analysis at build time (#37) -- Updated dependencies [230ab19] - - @photonjs/core@0.1.8 - -## 0.1.6 - -### Patch Changes - -- e148965: feat: update dependencies - -## 0.1.5 - -### Patch Changes - -- 5be6fd4: fix: make sure Durable Objects are exported - -## 0.1.4 - -### Patch Changes - -- 5a4c3d5: fix: upgrade dependencies -- Updated dependencies [5a4c3d5] - - @photonjs/core@0.1.4 - -## 0.1.3 - -### Patch Changes - -- baaaaf9: fix: missing virtual prefix is zod literal -- Updated dependencies [baaaaf9] - - @photonjs/core@0.1.3 - -## 0.1.2 - -### Patch Changes - -- 623579c: fix(deps): upgrade zod -- Updated dependencies [623579c] - - @photonjs/core@0.1.2 - -## 0.1.1 - -### Patch Changes - -- f3472b7: refactor: prefix all virtual modules with virtual: -- Updated dependencies [589ae48] -- Updated dependencies [f3472b7] - - @photonjs/core@0.1.1 - -## 0.1.0 - -### Minor Changes - -- 90c6e01: Release as 0.1.0 - -### Patch Changes - -- Updated dependencies [90c6e01] - - @photonjs/core@0.1.0 - -## 0.0.16 - -### Patch Changes - -- d2e67f8: feat: upgrade dependencies -- Updated dependencies [d2e67f8] - - @photonjs/core@0.0.16 - -## 0.0.15 - -### Patch Changes - -- Updated dependencies [371c2e6] - - @photonjs/core@0.0.15 - -## 0.0.14 - -### Patch Changes - -- 82a785f: feat: bump @cloudflare/vite-plugin to support virtual main entries -- Updated dependencies [8cb65bb] - - @photonjs/core@0.0.14 - -## 0.0.13 - -### Patch Changes - -- b01b2e4: fix: upgrade @universal-middleware/h3 - -## 0.0.12 - -### Patch Changes - -- 5659f49: fix: properly compute optimizeDeps -- Updated dependencies [5659f49] - - @photonjs/core@0.0.13 - -## 0.0.11 - -### Patch Changes - -- 5a90439: feat: upgrade dependencies -- Updated dependencies [5a90439] - - @photonjs/core@0.0.12 - -## 0.0.10 - -### Patch Changes - -- 26b7ab8: fix: bundle /virtual types - -## 0.0.9 - -### Patch Changes - -- Updated dependencies [6a892a8] - - @photonjs/core@0.0.11 - -## 0.0.8 - -### Patch Changes - -- 20f3404: chore: improve cloudflare support -- Updated dependencies [20f3404] - - @photonjs/core@0.0.10 - -## 0.0.7 - -### Patch Changes - -- Updated dependencies [78e177a] - - @photonjs/core@0.0.9 - -## 0.0.6 - -### Patch Changes - -- 28135a8: feat: add support for srvx -- Updated dependencies [28135a8] - - @photonjs/core@0.0.8 - -## 0.0.5 - -### Patch Changes - -- Updated dependencies [33c4dfe] - - @photonjs/core@0.0.7 - -## 0.0.4 - -### Patch Changes - -- Updated dependencies [3792886] - - @photonjs/core@0.0.6 - -## 0.0.3 - -### Patch Changes - -- Updated dependencies [12e246a] - - @photonjs/core@0.0.5 - -## 0.0.2 - -### Patch Changes - -- eb082b2: feat: split photon into multiple packages -- Updated dependencies [eb082b2] - - @photonjs/core@0.0.4 - -### Bug Fixes - -- better virtual module resolution fix ([9ec0fa0](https://github.com/photon-js/photon/commit/9ec0fa06cbd9e72858fc173aec0905865cef32ff)) - -### Features - -- cloudflare adapter ([47c8653](https://github.com/photon-js/photon/commit/47c8653f5283cf57a6c5d95e877eedb0ecb7108a)) -- improve core to support vercel ([d561ca3](https://github.com/photon-js/photon/commit/d561ca3894de6e54cceb38d523c0fa86725615ea)) diff --git a/packages/adapter-cloudflare/README.md b/packages/adapter-cloudflare/README.md deleted file mode 100644 index b8132e58..00000000 --- a/packages/adapter-cloudflare/README.md +++ /dev/null @@ -1,213 +0,0 @@ -# @photonjs/cloudflare - -Cloudflare Workers and Pages adapter for Photon, enabling deployment of universal web applications to Cloudflare's edge network. - -## Overview - -This adapter provides seamless integration between Photon and Cloudflare's runtime environments: -- **Cloudflare Workers**: Deploy server functions to Cloudflare's edge network -- **Cloudflare Pages**: Static site hosting with edge functions -- **Workerd Runtime**: Local development with Cloudflare's runtime -- **WebSocket Support**: Real-time applications with crossws integration -- **H3 Integration**: Built-in support for H3 server framework - -## Installation - -```bash -npm install @photonjs/cloudflare -# or -pnpm add @photonjs/cloudflare -# or -yarn add @photonjs/cloudflare -``` - -## Usage - -### Basic Setup - -Add the Cloudflare adapter to your Vite configuration: - -```ts -// vite.config.ts -import { installPhoton } from '@photonjs/runtime/vite' -import { cloudflare } from '@photonjs/cloudflare/vite' - -export default { - plugins: [ - installPhoton({ - // optional - server: './src/server.ts' - }), - cloudflare() - ] -} -``` - -### Wrangler Configuration - -Configure Wrangler to use your Photon's virtual entry: - -```toml -# wrangler.toml -name = "my-photon-app" -main = "virtual:photon:cloudflare:server-entry" -compatibility_date = "2025-08-28" -``` - -### Server Integration - -#### With Hono - -```ts -// src/server.ts -import { Hono } from 'hono' -import { apply, serve } from '@photonjs/hono' - -const app = new Hono() - -app.get('/', (c) => c.text('Hello from Photon + Hono on Cloudflare!')) - -apply(app) -export default serve(app) -``` - -#### With H3 - -```ts -// src/server.ts -import { createApp, defineEventHandler } from 'h3' -import { apply, serve } from '@photonjs/h3' - -const app = createApp() - -app.use('/', defineEventHandler(() => 'Hello from Photon + H3 on Cloudflare!')) - -apply(app) -export default serve(app) -``` - -## API Reference - -### Exports - -- `./vite` - Vite plugin for Cloudflare integration -- `./hono` - Hono-specific Cloudflare utilities -- `./h3` - H3-specific Cloudflare utilities -- `./srvx` - srvx-specific Cloudflare utilities -- `./dev` - Development server utilities -- `./virtual` - TypeScript declarations for virtual modules - -### Cloudflare-specific Functions - -#### `asFetch(app): ExportedHandlerFetchHandler` - -Converts a Hono app to a Cloudflare Workers fetch handler: - -```ts -import { asFetch } from '@photonjs/cloudflare/hono' -import { Hono } from 'hono' - -const app = new Hono() -export default { fetch: asFetch(app) } -``` - -## Development - -### Local Development with Workerd - -```bash -# Development with Cloudflare's workerd runtime -npm run dev:cloudflare -# or -pnpm dev:cloudflare -``` - -### Building for Production - -```bash -# Build for Cloudflare deployment -npm run build:cloudflare -# or -pnpm build:cloudflare -``` - -## Environment Variables - -Access Cloudflare environment variables and bindings: - -```ts -// In your handlers -export default { - async fetch(request, env, ctx) { - // env contains your Cloudflare bindings - const value = env.MY_KV_NAMESPACE.get('key') - // ... - } -} -``` - -## WebSocket Support - -Enable WebSocket support with crossws: - -```bash -npm install crossws -``` - -```ts -// vite.config.ts -export default { - plugins: [ - photon({ - server: './src/server.ts' - }), - cloudflare({ - // WebSocket support will be automatically detected - }) - ] -} -``` - -## Examples - -See the example applications: -- [Basic Cloudflare App](../../example/app-cloudflare) -- [Hono + Cloudflare App](../../example/app-hono) - -## Deployment - -### Using Wrangler - -```bash -# Deploy to Cloudflare Workers -wrangler deploy - -# Deploy to Cloudflare Pages -wrangler pages deploy dist -``` - -### Using GitHub Actions - -```yaml -# .github/workflows/deploy.yml -name: Deploy to Cloudflare -on: - push: - branches: [main] - -jobs: - deploy: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - - run: npm install - - run: npm run build:cloudflare - - uses: cloudflare/wrangler-action@v3 - with: - apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} -``` - -## License - -MIT diff --git a/packages/adapter-cloudflare/package.json b/packages/adapter-cloudflare/package.json deleted file mode 100644 index 3367ceaa..00000000 --- a/packages/adapter-cloudflare/package.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "name": "@photonjs/cloudflare", - "version": "0.1.13", - "type": "module", - "main": "./dist/index.js", - "types": "./dist/index.d.ts", - "exports": { - ".": "./dist/index.js", - "./vite": "./dist/vite.js", - "./virtual": { - "types": "./virtual.d.ts" - } - }, - "scripts": { - "dev": "tsdown --watch", - "build": "tsdown", - "test:types": "tsc --noEmit" - }, - "dependencies": { - "@cloudflare/vite-plugin": "^1.19.0", - "@photonjs/core": "workspace:^", - "@universal-middleware/cloudflare": "^0.4.10" - }, - "devDependencies": { - "@cloudflare/workers-types": "^4.20251219.0", - "tsdown": "^0.18.1", - "typescript": "^5.9.3", - "vite": "^7.2.4" - }, - "files": [ - "dist/", - "virtual.d.ts" - ], - "repository": "github:photon-js/photon", - "license": "MIT" -} diff --git a/packages/adapter-cloudflare/src/index.ts b/packages/adapter-cloudflare/src/index.ts deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/adapter-cloudflare/src/plugin.ts b/packages/adapter-cloudflare/src/plugin.ts deleted file mode 100644 index 0a7f9908..00000000 --- a/packages/adapter-cloudflare/src/plugin.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { cloudflare as cloudflareVitePlugins, type PluginConfig } from "@cloudflare/vite-plugin"; -import { supportedTargetServers, targetLoader } from "@photonjs/core/vite"; -import type { Plugin } from "vite"; - -const moduleId = "photon:cloudflare"; - -export function cloudflare(config?: PluginConfig): Plugin[] { - const defaultBuildEnv = config?.viteEnvironment?.name ?? "ssr"; - - return [ - { - name: `${moduleId}:config`, - enforce: "pre", - config: { - handler() { - return { - photon: { - // @cloudflare/vite-plugin has its own dev server - devServer: false, - codeSplitting: { - target: false, - }, - defaultBuildEnv, - // Cloudflare emits its own index entry - emitEntry: false, - }, - }; - }, - }, - }, - { - name: `${moduleId}:shorthand`, - - resolveId: { - order: "pre", - filter: { - // User-facing module ID shorthand for wrangler config file - id: /virtual:photon:cloudflare:server-entry/, - }, - - handler(_id, importer, opts) { - return this.resolve("virtual:photon:cloudflare:virtual:photon:server-entry", importer, opts); - }, - }, - - sharedDuringBuild: true, - }, - ...targetLoader("cloudflare", { - async load(id) { - return { - // language=ts - code: `import entry from ${JSON.stringify(id)}; - -export default { - ...entry -}; -export * from ${JSON.stringify(id)};`, - map: { mappings: "" }, - }; - }, - }), - supportedTargetServers("cloudflare", ["hono", "h3", "srvx"]), - ...cloudflareVitePlugins({ - ...config, - viteEnvironment: { ...config?.viteEnvironment, name: defaultBuildEnv }, - }), - ]; -} diff --git a/packages/adapter-cloudflare/tsconfig.json b/packages/adapter-cloudflare/tsconfig.json deleted file mode 100644 index db11ceaa..00000000 --- a/packages/adapter-cloudflare/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.base.json", - "include": ["**/*"], - "compilerOptions": { - "composite": true, - "types": ["vite/client"], - "outDir": "./dist/" - } -} diff --git a/packages/adapter-cloudflare/tsdown.config.ts b/packages/adapter-cloudflare/tsdown.config.ts deleted file mode 100644 index 623e2ea1..00000000 --- a/packages/adapter-cloudflare/tsdown.config.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { defineConfig, type UserConfig as TsdownOptions } from "tsdown"; - -const commonOptions = { - format: ["esm"], - target: "es2022", - dts: true, - outDir: "dist", - treeshake: true, - nodeProtocol: true, - fixedExtension: false, - external: [/^virtual:photon:get-middlewares:/, /^@photonjs\/core\/dev/, /^@photonjs\/cloudflare/], -} satisfies TsdownOptions; - -export default defineConfig([ - { - ...commonOptions, - platform: "node", - entry: { - index: "./src/index.ts", - vite: "./src/plugin.ts", - }, - }, -]); diff --git a/packages/adapter-cloudflare/virtual.d.ts b/packages/adapter-cloudflare/virtual.d.ts deleted file mode 100644 index 167dc87d..00000000 --- a/packages/adapter-cloudflare/virtual.d.ts +++ /dev/null @@ -1,3 +0,0 @@ -declare module "photon:cloudflare:photon:server-entry" { - export const fetch: import("@cloudflare/workers-types").ExportedHandlerFetchHandler; -} diff --git a/packages/adapter-netlify/CHANGELOG.md b/packages/adapter-netlify/CHANGELOG.md deleted file mode 100644 index db2ea160..00000000 --- a/packages/adapter-netlify/CHANGELOG.md +++ /dev/null @@ -1,57 +0,0 @@ -# @photonjs/netlify - -## 0.1.3 - -### Patch Changes - -- 9e4534b: fix: upgrade dependencies -- Updated dependencies [9e4534b] - - @photonjs/core@0.1.20 - -## 0.1.2 - -### Patch Changes - -- Updated dependencies [5fd9297] - - @photonjs/core@0.1.19 - -## 0.1.2-beta.0 - -### Patch Changes - -- Updated dependencies [5fd9297] - - @photonjs/core@0.1.19-beta.0 - -## 0.1.1 - -### Patch Changes - -- 8815d51: stable release -- Updated dependencies [8815d51] - - @photonjs/core@0.1.16 - -## 0.1.0 - -### Minor Changes - -- c3b669a: feat: add Netlify adapter - -### Patch Changes - -- 525d541: feat: better compatibility with Bun and Deno -- Updated dependencies [525d541] -- Updated dependencies [c3b669a] - - @photonjs/core@0.1.15 - -## 0.1.0-beta.0 - -### Minor Changes - -- c3b669a: feat: add Netlify adapter - -### Patch Changes - -- 525d541: feat: better compatibility with Bun and Deno -- Updated dependencies [525d541] -- Updated dependencies [c3b669a] - - @photonjs/core@0.1.15-beta.0 diff --git a/packages/adapter-netlify/index.ts b/packages/adapter-netlify/index.ts deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/adapter-netlify/package.json b/packages/adapter-netlify/package.json deleted file mode 100644 index f8db504f..00000000 --- a/packages/adapter-netlify/package.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "name": "@photonjs/netlify", - "version": "0.1.3", - "type": "module", - "main": "./dist/index.js", - "types": "./dist/index.d.ts", - "exports": { - ".": "./dist/index.js", - "./vite": "./dist/vite.js" - }, - "scripts": { - "dev": "tsdown --watch", - "build": "tsdown", - "test:types": "tsc --noEmit" - }, - "dependencies": { - "@netlify/vite-plugin": "^2.7.17", - "@photonjs/core": "workspace:^" - }, - "devDependencies": { - "tsdown": "^0.18.1", - "typescript": "^5.9.3", - "vite": "^7.2.4" - }, - "files": [ - "dist/", - "virtual.d.ts" - ], - "repository": "github:photon-js/photon", - "license": "MIT" -} diff --git a/packages/adapter-netlify/src/index.ts b/packages/adapter-netlify/src/index.ts deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/adapter-netlify/src/plugin.ts b/packages/adapter-netlify/src/plugin.ts deleted file mode 100644 index 56127feb..00000000 --- a/packages/adapter-netlify/src/plugin.ts +++ /dev/null @@ -1,54 +0,0 @@ -import createNetlifyPlugin, { type NetlifyPluginOptions } from "@netlify/vite-plugin"; -import { supportedTargetServers, targetLoader } from "@photonjs/core/vite"; -import type { Plugin } from "vite"; - -const moduleId = "photon:netlify"; - -export function netlify(config?: NetlifyPluginOptions): Plugin[] { - return [ - { - name: `${moduleId}:config`, - enforce: "pre", - config: { - handler() { - return { - photon: { - /** - * @netlify/vite-plugin does not support code splitting yet - * @see https://docs.netlify.com/build/frameworks/frameworks-api/ - */ - codeSplitting: { - target: false, - }, - emitEntry: false, - }, - }; - }, - }, - }, - ...targetLoader("netlify", { - async load(id) { - return { - // language=ts - code: `import entry from ${JSON.stringify(id)}; - -export default { - ...entry -}; -export * from ${JSON.stringify(id)};`, - map: { mappings: "" }, - }; - }, - }), - // Some examples in Netlify's documentation are using serverless-http for express - // and other node-specific frameworks compatibility, but that is not recommended by Photon. - supportedTargetServers("netlify", ["hono", "h3", "srvx"]), - ...createNetlifyPlugin({ - ...config, - build: { - enabled: true, - ...config?.build, - }, - }), - ]; -} diff --git a/packages/adapter-netlify/tsconfig.json b/packages/adapter-netlify/tsconfig.json deleted file mode 100644 index db11ceaa..00000000 --- a/packages/adapter-netlify/tsconfig.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "extends": "../../tsconfig.base.json", - "include": ["**/*"], - "compilerOptions": { - "composite": true, - "types": ["vite/client"], - "outDir": "./dist/" - } -} diff --git a/packages/adapter-netlify/tsdown.config.ts b/packages/adapter-netlify/tsdown.config.ts deleted file mode 100644 index e8a5ff4c..00000000 --- a/packages/adapter-netlify/tsdown.config.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { defineConfig, type UserConfig as TsdownOptions } from "tsdown"; - -const commonOptions = { - format: ["esm"], - target: "es2022", - dts: true, - outDir: "dist", - treeshake: true, - nodeProtocol: true, - fixedExtension: false, - external: [/^virtual:photon:get-middlewares:/, /^@photonjs\/core\/dev/, /^@photonjs\/netlify/], -} satisfies TsdownOptions; - -export default defineConfig([ - { - ...commonOptions, - platform: "node", - entry: { - index: "./src/index.ts", - vite: "./src/plugin.ts", - }, - }, -]); diff --git a/packages/adapter-vercel/CHANGELOG.md b/packages/adapter-vercel/CHANGELOG.md deleted file mode 100644 index 0b38735e..00000000 --- a/packages/adapter-vercel/CHANGELOG.md +++ /dev/null @@ -1,215 +0,0 @@ -# @photonjs/vercel - -## 0.1.22 - -### Patch Changes - -- 9e4534b: fix: upgrade dependencies -- Updated dependencies [9e4534b] - - @photonjs/runtime@0.1.16 - - @photonjs/core@0.1.20 - -## 0.1.21 - -### Patch Changes - -- Updated dependencies [5fd9297] - - @photonjs/core@0.1.19 - - @photonjs/runtime@0.1.15 - -## 0.1.21-beta.0 - -### Patch Changes - -- Updated dependencies [5fd9297] - - @photonjs/core@0.1.19-beta.0 - - @photonjs/runtime@0.1.15-beta.0 - -## 0.1.20 - -### Patch Changes - -- 866f41d: fix: ensure static files copy if root is defined - -## 0.1.19 - -### Patch Changes - -- 04e0a04: fix: ensure static files copy if root is defined - -## 0.1.18 - -### Patch Changes - -- 8815d51: stable release -- Updated dependencies [8815d51] - - @photonjs/core@0.1.16 - - @photonjs/runtime@0.1.13 - -## 0.1.17 - -### Patch Changes - -- 525d541: feat: better compatibility with Bun and Deno -- 3547430: fix: .vercel folder should ignore root override -- Updated dependencies [525d541] -- Updated dependencies [c3b669a] - - @photonjs/core@0.1.15 - - @photonjs/runtime@0.1.12 - -## 0.1.17-beta.0 - -### Patch Changes - -- 525d541: feat: better compatibility with Bun and Deno -- 3547430: fix: .vercel folder should ignore root override -- Updated dependencies [525d541] -- Updated dependencies [c3b669a] - - @photonjs/core@0.1.15-beta.0 - - @photonjs/runtime@0.1.12-beta.0 - -## 0.1.16 - -### Patch Changes - -- 3624066: fix: .vercel folder should ignore root override - -## 0.1.15 - -### Patch Changes - -- 668c4f7: fix: upgrade dependencies -- Updated dependencies [e98e935] -- Updated dependencies [668c4f7] - - @photonjs/runtime@0.1.11 - - @photonjs/core@0.1.14 - -## 0.1.14 - -### Patch Changes - -- 42c36e7: fix: bump @universal-middleware/vercel -- Updated dependencies [20ec533] - - @photonjs/core@0.1.13 - -## 0.1.13 - -### Patch Changes - -- d1c8ded: fix: bump @universal-middleware/vercel - -## 0.1.12 - -### Patch Changes - -- b861a04: fix: srvx + edge should still be wrapped - -## 0.1.11 - -### Patch Changes - -- b370ef5: feat: simpler vercel adapter if using srvx - -## 0.1.10 - -### Patch Changes - -- 14322df: feat: simpler vercel adapter if using srvx - -## 0.1.9 - -### Patch Changes - -- cc7b79d: fix: bump @universal-middleware/express -- Updated dependencies [e062fec] -- Updated dependencies [cc7b79d] - - @photonjs/core@0.1.12 - -## 0.1.8 - -### Patch Changes - -- 0d3faed: feat(hmr): do not forward HMR WS requests through photon server -- 0d3faed: feat: support `{ fetch }` entries -- 0d3faed: feat: HMR support for Deno and Bun -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] -- Updated dependencies [0d3faed] - - @photonjs/core@0.1.9 - - @photonjs/runtime@0.1.7 - -## 0.1.7 - -### Patch Changes - -- 230ab19: revert: fix: remove static analysis at build time (#37) -- Updated dependencies [230ab19] - - @photonjs/core@0.1.8 - - @photonjs/runtime@0.1.6 - -## 0.1.6 - -### Patch Changes - -- e148965: feat: update dependencies -- Updated dependencies [e148965] - - @photonjs/runtime@0.1.5 - -## 0.1.5 - -### Patch Changes - -- 5a4c3d5: fix: upgrade dependencies -- Updated dependencies [5a4c3d5] - - @photonjs/runtime@0.1.4 - - @photonjs/core@0.1.4 - -## 0.1.4 - -### Patch Changes - -- baaaaf9: fix: missing virtual prefix is zod literal -- Updated dependencies [baaaaf9] - - @photonjs/core@0.1.3 - - @photonjs/runtime@0.1.3 - -## 0.1.3 - -### Patch Changes - -- 623579c: fix(deps): upgrade zod -- Updated dependencies [623579c] - - @photonjs/core@0.1.2 - - @photonjs/runtime@0.1.2 - -## 0.1.2 - -### Patch Changes - -- f3472b7: refactor: prefix all virtual modules with virtual: -- Updated dependencies [589ae48] -- Updated dependencies [f3472b7] - - @photonjs/core@0.1.1 - - @photonjs/runtime@0.1.1 - -## 0.1.1 - -### Patch Changes - -- Updated dependencies [90c6e01] - - @photonjs/core@0.1.0 - - @photonjs/runtime@0.1.0 - -## 0.1.0 - -### Minor Changes - -- d2e67f8: feat: @photonjs/vercel adapter - -### Patch Changes - -- Updated dependencies [d2e67f8] - - @photonjs/runtime@0.0.14 - - @photonjs/core@0.0.16 diff --git a/packages/adapter-vercel/README.md b/packages/adapter-vercel/README.md deleted file mode 100644 index c328adbf..00000000 --- a/packages/adapter-vercel/README.md +++ /dev/null @@ -1,112 +0,0 @@ -# @photonjs/vercel -Vercel adapter for [Photon](https://photonjs.dev/). - -Bundle your Vite application as supported by [Vercel Output API (v3)](https://vercel.com/docs/build-output-api/v3). - -## Install - -```bash -npm i -D @photonjs/vercel -``` - -```bash -yarn add -D @photonjs/vercel -``` - -```bash -pnpm add -D @photonjs/vercel -``` - -```bash -bun add -D @photonjs/vercel -``` - -## Features - -- [x] [SSG/Static files](https://vercel.com/docs/build-output-api/v3/primitives#static-files) - - see [`prerender` config](/packages/vercel/src/types.ts#L37) -- [x] [SSR/Serverless functions](https://vercel.com/docs/build-output-api/v3/primitives#serverless-functions) - - `.[jt]s` files under the `/api` folder of your project are automatically bundled as Serverless functions under `.vercel/output/functions/api/*.func` - - see [`additionalEndpoints` config](/packages/vercel/src/types.ts#L62) -- [x] [ISR/Prerender functions](https://vercel.com/docs/build-output-api/v3/primitives#prerender-functions) - - see [`isr` config](/packages/vercel/src/types.ts#L89). Also see implementation of [vike](/packages/vike-integration/vike.ts) for example -- [x] [Edge functions](https://vercel.com/docs/build-output-api/v3/primitives#edge-functions) -- [x] [Edge middleware](https://vercel.com/docs/functions/edge-middleware/middleware-api) -- [ ] [Images optimization](https://vercel.com/docs/build-output-api/v3/configuration#images) -- [ ] [Preview mode](https://vercel.com/docs/build-output-api/v3/features#preview-mode) -- [x] [Advanced config](/packages/vercel/src/types.ts#L19) - -## Simple usage - -Install this package as a dev dependency and add it to your Vite config: - -```ts -// vite.config.ts -import { defineConfig } from 'vite'; -import vercel from '@photonjs/vercel'; -import { getEntriesFromFs } from "@photonjs/vercel/utils"; - -export default defineConfig({ - plugins: [vercel({ - entries: [ - ...(await getEntriesFromFs("endpoints/api", { - // Auto mapping examples: - // endpoints/api/page.ts -> /api/page - // endpoints/api/name/[name].ts -> /api/name/* - destination: "api", - })) - ] - })], -}); -``` - -> [!NOTE] -> `@vercel/build` currently forces the building of files in the _/api_ folder, with no way to disable this behavior. -> It's recommended to place your files in a different folder. - -### Configure endpoints - -Endpoints added via `getEntriesFromFs` can be configured by exporting values from the endpoint file: - -```ts -// file: endpoints/api/endpoint.ts - -// Should run on edge runtime -export const edge = true; - -// Always add those header to this endpoint -export const headers = { - 'Some-Header': 'some value', -}; - -// Stream the response -export const streaming = true; - -// Enable Incremental Static Regeneration for this endpoint -export const isr = { - expiration: 30, -}; - -export default async function handler() { - return new Response('Edge Function: OK', { - status: 200, - }); -} -``` - -### Edge middleware - -You can use [Edge middleware as describe in the official documentation](https://vercel.com/docs/functions/edge-middleware/middleware-api) (i.e. with a `middleware.ts` file at the root of your project). - -## FAQ - -### What does ISR do in dev mode? -Nothing. It's a production-only feature - -### What does `edge: true` target do in dev mode? -Nothing (yet?). If you have a use-case where an actual Edge runtime would be necessary in dev, please open a discussion - -### I don't see Vercel specific headers in dev mode -This is not yet supported. Please open an issue if you need this (PR welcome). - -Related documentation: https://vercel.com/docs/edge-network/headers/request-headers diff --git a/packages/adapter-vercel/package.json b/packages/adapter-vercel/package.json deleted file mode 100644 index ce03ee0c..00000000 --- a/packages/adapter-vercel/package.json +++ /dev/null @@ -1,63 +0,0 @@ -{ - "name": "@photonjs/vercel", - "version": "0.1.22", - "type": "module", - "files": [ - "dist", - "*.d.ts" - ], - "module": "./dist/index.js", - "exports": { - ".": "./dist/index.js", - "./vite": "./dist/vite.js", - "./universal-middleware": "./dist/universal-middleware-prod.js", - "./universal-middleware/dev": "./dist/universal-middleware-dev.js", - "./utils": "./dist/utils.js", - "./api": "./dist/api.js", - "./types": { - "types": "./dist/types.d.ts" - } - }, - "description": "Vercel adapter for vite", - "author": "Joël Charles ", - "repository": "https://github.com/magne4000/vite-plugin-vercel", - "license": "MIT", - "scripts": { - "dev": "tsdown --watch", - "build": "tsdown", - "test:types": "tsc --noEmit" - }, - "peerDependencies": { - "vite": ">=7.1", - "@photonjs/core": "workspace:^", - "@photonjs/runtime": "workspace:^" - }, - "devDependencies": { - "@types/node": "^20.19.25", - "@universal-middleware/express": "^0.4.22", - "@vercel/node": "^5.5.16", - "rollup": "^4.53.5", - "tsdown": "^0.18.1", - "typescript": "^5.9.3", - "vite": "^7.2.4" - }, - "dependencies": { - "@brillout/libassert": "^0.5.8", - "@manypkg/find-root": "^3.1.0", - "@photonjs/core": "workspace:^", - "@photonjs/runtime": "workspace:^", - "@universal-middleware/core": "^0.4.14", - "@universal-middleware/vercel": "^0.4.29", - "@vercel/build-utils": "^13.2.4", - "@vercel/nft": "^1.1.1", - "@vercel/routing-utils": "^5.3.1", - "@vite-plugin-vercel/schemas": "latest", - "convert-route": "^0.1.2", - "esbuild": "^0.27.2", - "fast-glob": "^3.3.3", - "magicast": "^0.5.1", - "path-to-regexp": "^8.3.0", - "strip-ansi": "^7.1.2", - "vite-plugin-wasm": "^3.5.0" - } -} diff --git a/packages/adapter-vercel/src/api.ts b/packages/adapter-vercel/src/api.ts deleted file mode 100644 index 105176ac..00000000 --- a/packages/adapter-vercel/src/api.ts +++ /dev/null @@ -1,95 +0,0 @@ -import type { Photon } from "@photonjs/core"; -import type { VercelOutputConfig } from "@vite-plugin-vercel/schemas"; -import type { PluginContext } from "rollup"; -import type { Plugin, ViteDevServer } from "vite"; -import { assert } from "./assert"; -import type { ViteVercelConfig } from "./types"; - -export function createAPI(outfiles: ViteVercelOutFile[], pluginConfig: ViteVercelConfig) { - return { - /** - * @internal - */ - getOutFiles(): ViteVercelOutFile[] { - return outfiles; - }, - get config(): Partial> { - pluginConfig.config ??= {}; - return pluginConfig.config; - }, - get defaultMaxDuration() { - return pluginConfig.defaultMaxDuration; - }, - set defaultMaxDuration(value) { - pluginConfig.defaultMaxDuration = value; - }, - get expiration() { - return pluginConfig.expiration; - }, - set expiration(value) { - pluginConfig.expiration = value; - }, - get rewrites() { - pluginConfig.rewrites ??= []; - return pluginConfig.rewrites; - }, - get headers() { - pluginConfig.headers ??= []; - return pluginConfig.headers; - }, - get redirects() { - pluginConfig.redirects ??= []; - return pluginConfig.redirects; - }, - get cleanUrls() { - return pluginConfig.cleanUrls; - }, - set cleanUrls(value) { - pluginConfig.cleanUrls = value; - }, - get trailingSlash() { - return pluginConfig.trailingSlash; - }, - set trailingSlash(value) { - pluginConfig.trailingSlash = value; - }, - get defaultSupportsResponseStreaming() { - return pluginConfig.defaultSupportsResponseStreaming; - }, - set defaultSupportsResponseStreaming(value) { - pluginConfig.defaultSupportsResponseStreaming = value; - }, - }; -} - -// TODO PluginContext is too specific and can generate mismatch when using this helper -export function getVercelAPI(pluginContextOrServer: PluginContext | ViteDevServer) { - const config = - "environment" in pluginContextOrServer ? pluginContextOrServer.environment.config : pluginContextOrServer.config; - const vpv: Plugin<(pluginContext?: PluginContext) => ViteVercelApi> | undefined = config.plugins.find( - (p) => p.name === "vite-plugin-vercel:api", - ); - assert(vpv, "Could not find vite-plugin-vercel:api plugin"); - assert(vpv.api, "Missing `api`. Make sure vite-plugin-vercel is up-to-date"); - - return vpv.api("environment" in pluginContextOrServer ? pluginContextOrServer : undefined); -} - -export type ViteVercelApi = ReturnType; - -export type ViteVercelOutFile = ViteVercelOutFileChunk | ViteVercelOutFileAsset; - -interface ViteVercelOutFileCommon { - filepath: string; - root: string; - outdir: string; -} - -export interface ViteVercelOutFileChunk extends ViteVercelOutFileCommon { - type: "chunk"; - relatedEntry: Photon.Entry; -} - -export interface ViteVercelOutFileAsset extends ViteVercelOutFileCommon { - type: "asset"; -} diff --git a/packages/adapter-vercel/src/assert.ts b/packages/adapter-vercel/src/assert.ts deleted file mode 100644 index 9078079e..00000000 --- a/packages/adapter-vercel/src/assert.ts +++ /dev/null @@ -1,11 +0,0 @@ -// @ts-expect-error no type definition -import { newError } from "@brillout/libassert"; - -export function assert(condition: unknown, errorMessage: string): asserts condition { - if (condition) { - return; - } - - const err = newError(`[@photonjs/vercel] ${errorMessage}`, 2); - throw err; -} diff --git a/packages/adapter-vercel/src/build.ts b/packages/adapter-vercel/src/build.ts deleted file mode 100644 index 16f3c3cc..00000000 --- a/packages/adapter-vercel/src/build.ts +++ /dev/null @@ -1,29 +0,0 @@ -import type { NodeVersion } from "@vercel/build-utils"; -import { vercelOutputVcConfigSchema } from "@vite-plugin-vercel/schemas"; -import type { ViteVercelConfig } from "./types"; - -export function getVcConfig( - pluginConfig: ViteVercelConfig, - filename: string, - options: { - edge: boolean; - nodeVersion: NodeVersion; - streaming?: boolean; - }, -) { - return vercelOutputVcConfigSchema.parse( - options.edge - ? { - runtime: "edge", - entrypoint: filename, - } - : { - runtime: options.nodeVersion.runtime, - handler: filename, - maxDuration: pluginConfig.defaultMaxDuration, - launcherType: "Nodejs", - shouldAddHelpers: true, - supportsResponseStreaming: options.streaming ?? pluginConfig.defaultSupportsResponseStreaming, - }, - ); -} diff --git a/packages/adapter-vercel/src/config.ts b/packages/adapter-vercel/src/config.ts deleted file mode 100644 index 291740a6..00000000 --- a/packages/adapter-vercel/src/config.ts +++ /dev/null @@ -1,82 +0,0 @@ -import { getTransformedRoutes, mergeRoutes, normalizeRoutes, type Route } from "@vercel/routing-utils"; -import { type VercelOutputConfig, vercelOutputConfigSchema } from "@vite-plugin-vercel/schemas"; -import type { ViteVercelConfig, ViteVercelRewrite } from "./types"; - -function reorderEnforce(arr: T[]) { - return [ - ...arr.filter((r) => r.enforce === "pre"), - ...arr.filter((r) => !r.enforce), - ...arr.filter((r) => r.enforce === "post"), - ]; -} - -export function getConfig(pluginConfig: ViteVercelConfig): VercelOutputConfig { - const _rewrites: ViteVercelRewrite[] = [...(pluginConfig.rewrites ?? [])]; - - const { routes, error } = getTransformedRoutes({ - cleanUrls: pluginConfig.cleanUrls ?? true, - trailingSlash: pluginConfig.trailingSlash, - rewrites: reorderEnforce(_rewrites), - redirects: pluginConfig.redirects ? reorderEnforce(pluginConfig.redirects) : undefined, - headers: pluginConfig.headers, - }); - - if (error) { - throw error; - } - - if ( - pluginConfig.config?.routes && - pluginConfig.config.routes.length > 0 && - !pluginConfig.config.routes.every((r) => "continue" in r && r.continue) - ) { - console.warn( - 'Did you forget to add `"continue": true` to your routes? See https://vercel.com/docs/build-output-api/v3/configuration#source-route\n' + - "If not, it is discouraged to use `routes` config to override routes. " + - "Prefer using `rewrites` and `redirects`.", - ); - } - - let userRoutes: Route[] = []; - let buildRoutes: Route[] = []; - - if (pluginConfig.config?.routes) { - const norm = normalizeRoutes(pluginConfig.config.routes); - - if (norm.error) { - throw norm.error; - } - - userRoutes = norm.routes ?? []; - } - - if (routes) { - const norm = normalizeRoutes(routes); - - if (norm.error) { - throw norm.error; - } - - buildRoutes = norm.routes ?? []; - } - - const cleanRoutes = mergeRoutes({ - userRoutes, - builds: [ - { - use: "@vercel/node", - entrypoint: "index.mjs", - routes: buildRoutes, - }, - ], - }); - - return vercelOutputConfigSchema.parse({ - version: 3, - ...pluginConfig.config, - routes: cleanRoutes, - overrides: { - ...pluginConfig.config?.overrides, - }, - }); -} diff --git a/packages/adapter-vercel/src/helpers.ts b/packages/adapter-vercel/src/helpers.ts deleted file mode 100644 index c6ecdf88..00000000 --- a/packages/adapter-vercel/src/helpers.ts +++ /dev/null @@ -1,16 +0,0 @@ -import path from "node:path"; -import type { Environment } from "vite"; - -export function joinAbsolute(env_or_p0: Environment | string, p1: string, ...p: string[]) { - if (path.isAbsolute(p1)) { - return path.join(p1, ...p); - } - return path.join(typeof env_or_p0 === "string" ? env_or_p0 : env_or_p0.config.root, p1, ...p); -} - -export function joinAbsolutePosix(env_or_p0: Environment | string, p1: string, ...p: string[]) { - if (path.isAbsolute(p1)) { - return path.posix.join(p1, ...p); - } - return path.posix.join(typeof env_or_p0 === "string" ? env_or_p0 : env_or_p0.config.root, p1, ...p); -} diff --git a/packages/adapter-vercel/src/index.ts b/packages/adapter-vercel/src/index.ts deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/adapter-vercel/src/photon/universal-middleware-dev.ts b/packages/adapter-vercel/src/photon/universal-middleware-dev.ts deleted file mode 100644 index b1f64fba..00000000 --- a/packages/adapter-vercel/src/photon/universal-middleware-dev.ts +++ /dev/null @@ -1,28 +0,0 @@ -import "../types"; -import type { Photon } from "@photonjs/core"; -import { enhance, MiddlewareOrder, type UniversalMiddleware } from "@universal-middleware/core"; - -// FIXME during dev, we cannot add dynamic entries through this.emitFile. -// So for headers to be available in dev, we must create a middleware that will do that for us. -export const applyVercelHeaders: UniversalMiddleware< - // TODO export type from Photon - Universal.Context & { photon?: { handler?: Photon.EntryUniversalHandler; server?: Photon.EntryServer } } -> = (_request, context) => { - const headers = context.photon?.handler?.vercel?.headers ?? context.photon?.server?.vercel?.headers; - if (!headers) return; - - return (response) => { - for (const [key, value] of Object.entries(headers)) { - response.headers.set(key, value); - } - return response; - }; -}; - -export default [ - enhance(applyVercelHeaders, { - name: "vercel:headers", - immutable: true, - order: MiddlewareOrder.HEADER_MANAGEMENT, - }), -] as UniversalMiddleware[]; diff --git a/packages/adapter-vercel/src/photon/universal-middleware-prod.ts b/packages/adapter-vercel/src/photon/universal-middleware-prod.ts deleted file mode 100644 index 9b4961e9..00000000 --- a/packages/adapter-vercel/src/photon/universal-middleware-prod.ts +++ /dev/null @@ -1,15 +0,0 @@ -import "../types"; -import { enhance, type UniversalMiddleware } from "@universal-middleware/core"; -import { getOriginalRequest } from "../utils/original-request"; - -export const overrideVercelRequest: UniversalMiddleware = (request) => { - Object.assign(request, getOriginalRequest(request)); -}; - -export default [ - enhance(overrideVercelRequest, { - name: "vercel:request", - immutable: true, - order: Number.MIN_SAFE_INTEGER, - }), -] as UniversalMiddleware[]; diff --git a/packages/adapter-vercel/src/plugins/api.ts b/packages/adapter-vercel/src/plugins/api.ts deleted file mode 100644 index 4da04f87..00000000 --- a/packages/adapter-vercel/src/plugins/api.ts +++ /dev/null @@ -1,58 +0,0 @@ -import type { Photon } from "@photonjs/core"; -import type { Plugin } from "vite"; -import { createAPI, type ViteVercelOutFile } from "../api"; -import type { ViteVercelConfig } from "../types"; -import { photonEntryDestination } from "../utils/destination"; - -export function apiPlugin(pluginConfig: ViteVercelConfig): Plugin { - const outfiles: ViteVercelOutFile[] = []; - - return { - name: "vite-plugin-vercel:api", - - api() { - return createAPI(outfiles, pluginConfig); - }, - - // Compute outfiles for the API - writeBundle(_opts, bundle) { - if (this.environment.name !== "vercel_edge" && this.environment.name !== "vercel_node") return; - - const entries = this.environment.config.photon.entries; - const server = this.environment.config.photon.server; - const entryMapByDestination = new Map( - [server, ...Object.values(entries)].map((e) => [photonEntryDestination(e, ".func/index"), e]), - ); - - for (const entry of this.environment.config.photon.entries.filter((e) => e.type === "server-config")) { - entryMapByDestination.set(photonEntryDestination(entry, ".func/index"), entry); - } - - for (const [key, value] of Object.entries(bundle)) { - if (value.type === "chunk" && entryMapByDestination.has(removeExtension(key))) { - outfiles.push({ - type: "chunk", - root: this.environment.config.root, - outdir: this.environment.config.build.outDir, - filepath: key, - // biome-ignore lint/style/noNonNullAssertion: guarded by entryMap.has(...) - relatedEntry: entryMapByDestination.get(removeExtension(key))!, - }); - } else if ((value.type === "asset" && key.startsWith("functions/")) || key === "config.json") { - outfiles.push({ - type: "asset", - root: this.environment.config.root, - outdir: this.environment.config.build.outDir, - filepath: key, - }); - } - } - }, - - sharedDuringBuild: true, - }; -} - -function removeExtension(subject: string) { - return subject.replace(/\.[^/.]+$/, ""); -} diff --git a/packages/adapter-vercel/src/plugins/bundle.ts b/packages/adapter-vercel/src/plugins/bundle.ts deleted file mode 100644 index f5912372..00000000 --- a/packages/adapter-vercel/src/plugins/bundle.ts +++ /dev/null @@ -1,277 +0,0 @@ -import { existsSync, readFileSync, writeFileSync } from "node:fs"; -import { copyFile, mkdir, rm } from "node:fs/promises"; -import { builtinModules } from "node:module"; -import path from "node:path"; -import { findRoot } from "@manypkg/find-root"; -import { nodeFileTrace } from "@vercel/nft"; -import { type BuildOptions, build, type Plugin as ESBuildPlugin } from "esbuild"; -import type { Environment, Plugin } from "vite"; -import { getVercelAPI, type ViteVercelOutFile, type ViteVercelOutFileChunk } from "../api"; -import { joinAbsolute, joinAbsolutePosix } from "../helpers"; -import type { ViteVercelConfig } from "../types"; -import { edgeConditions } from "../utils/edge"; -import { isVercelLastBuildStep } from "../utils/env"; -import { edgeExternal } from "../utils/external"; - -const builtIns = new Set(builtinModules.flatMap((m) => [m, `node:${m}`])); - -const edgeWasmPlugin: ESBuildPlugin = { - name: "edge-wasm-vercel", - setup(build) { - build.onResolve({ filter: /\.wasm/ }, (args) => { - return { - path: args.path.replace(/\.wasm\?module$/i, ".wasm"), - external: true, - }; - }); - }, -}; - -// Treat dynamic imports of native modules as external -const dynamicNativeImportPlugin: ESBuildPlugin = { - name: "edge-dynamic-import-native", - setup(build) { - build.onResolve({ filter: /.*/ }, (args) => { - if (args.kind === "dynamic-import" && builtIns.has(args.path)) { - return { path: args.path, external: true }; - } - }); - }, -}; - -const reactEdgePlugin: ESBuildPlugin = { - name: "react-edge-plugin", - setup(build) { - build.onResolve({ filter: /^react-dom\/server$/ }, (args) => { - const { path: _, ...rest } = args; - return build.resolve("react-dom/server.edge", rest); - }); - }, -}; - -interface BundleAsset { - env: string; - root: string; - outDir: string; - fileName: string; - outFile: string; -} - -// We cannot disable code-splitting with Vite/Rollup, -// so we use esbuild when all files are written on the filesystem to bundle each function. -export function bundlePlugin(pluginConfig: ViteVercelConfig): Plugin[] { - const bundledAssets = new Map(); - - return [ - { - name: "vite-plugin-vercel:bundle", - enforce: "post", - apply: "build", - - generateBundle(_opts, bundle) { - for (const b of Object.values(bundle)) { - if (b.type === "asset") { - const originalFileNames = b.originalFileNames.map((relativePath) => - path.resolve(this.environment.config.root, relativePath), - ); - - const asset: BundleAsset = { - env: this.environment.name, - root: this.environment.config.root, - outDir: this.environment.config.build.outDir, - outFile: joinAbsolute(this.environment, this.environment.config.build.outDir, b.fileName), - fileName: b.fileName, - }; - - for (const originalFileName of originalFileNames) { - bundledAssets.set(originalFileName, asset); - } - } - } - }, - - closeBundle: { - order: "post", - async handler() { - if (!isVercelLastBuildStep(this.environment)) return; - - this.environment.logger.info("Creating Vercel bundles..."); - - const api = getVercelAPI(this); - const outfiles = api.getOutFiles(); - - // TODO concurrency - for (const outfile of outfiles) { - if (outfile.type === "asset") { - const { source, destination } = getAbsoluteOutFileWithout_tmp(outfile); - // TODO instead move from _tmp to parent folder - await mkdir(path.dirname(destination), { recursive: true }); - await copyFile(source, destination); - } else { - await bundle(this.environment, bundledAssets, outfile); - } - } - - const tmpDir = pluginConfig.outDir ? path.posix.join(pluginConfig.outDir, "_tmp") : ".vercel/output/_tmp"; - - await rm(tmpDir, { recursive: true }); - }, - }, - - sharedDuringBuild: true, - }, - ]; -} - -function getAbsoluteOutFileWithout_tmp(outfile: ViteVercelOutFile) { - const source = joinAbsolutePosix(outfile.root, outfile.outdir, outfile.filepath); - const destination = source.replace(outfile.outdir, outfile.outdir.replace(/_tmp(\/|\\|$)/, "")); - return { - source, - destination, - }; -} - -async function bundle( - environment: Environment, - bundledAssets: Map, - outfile: ViteVercelOutFileChunk, -) { - const { source, destination } = getAbsoluteOutFileWithout_tmp(outfile); - const isEdge = Boolean(outfile.relatedEntry.vercel?.edge); - - const buildOptions: BuildOptions = { - format: "esm", - target: "es2022", - legalComments: "none", - bundle: true, - entryPoints: [source], - treeShaking: true, - logOverride: { "ignored-bare-import": "silent" }, - }; - - if (isEdge) { - // TODO unenv behind an opt-out option - buildOptions.platform = "browser"; - buildOptions.external = edgeExternal; - buildOptions.conditions = edgeConditions; - buildOptions.define = { - "process.env.NODE_ENV": JSON.stringify("production"), - }; - buildOptions.outExtension = { ".js": ".mjs" }; - buildOptions.outfile = destination.replace(/\.mjs$/, ".js"); - buildOptions.plugins = [edgeWasmPlugin, dynamicNativeImportPlugin, reactEdgePlugin]; - } else { - buildOptions.platform = "node"; - buildOptions.outfile = destination.replace(/\.js$/, ".mjs"); - buildOptions.banner = { - js: `import { createRequire as topLevelCreateRequire } from 'module'; -import { dirname as topLevelDirname } from 'path'; -import { fileURLToPath as topLevelFileURLToPath } from 'url'; -const require = topLevelCreateRequire(import.meta.url); -const __filename = topLevelFileURLToPath(import.meta.url); -const __dirname = topLevelDirname(__filename); -`, - }; - } - - try { - await build(buildOptions); - } catch (e) { - // biome-ignore lint/suspicious/noTsIgnore: cause is not always defined - // @ts-ignore - throw new Error(`Error while bundling ${destination}`, { cause: e }); - } - - let base = environment.config.root; - try { - const dir = await findRoot(environment.config.root); - base = dir.rootDir; - } catch (_e) { - // ignore error - } - - const entryFilePath = existsSync(outfile.relatedEntry.id) - ? outfile.relatedEntry.id - : outfile.relatedEntry.resolvedId && existsSync(outfile.relatedEntry.resolvedId) - ? outfile.relatedEntry.resolvedId - : null; - - if (entryFilePath === null) { - return; - } - - const { fileList, reasons } = await nodeFileTrace([entryFilePath], { - base, - processCwd: environment.config.root, - mixedModules: true, - // https://github.com/vercel/next.js/blob/7c8e2b4e50449ce2d2c83de0b5638c61b7de2362/packages/next/src/build/collect-build-traces.ts#L201 - ignore: [ - "**/node_modules/react{,-dom,-dom-server-turbopack}/**/*.development.js", - "**/*.d.ts", - "**/*.map", - "**/node_modules/webpack5/**/*", - ], - async readFile(filepath) { - if (filepath.endsWith(".ts") || filepath.endsWith(".tsx")) { - const result = await build({ - target: "es2022", - format: "esm", - platform: "node", - logLevel: "info", - logOverride: { - "ignored-bare-import": "verbose", - "require-resolve-not-external": "verbose", - }, - minify: false, - plugins: [], - define: { - "process.env.NODE_ENV": '"production"', - "import.meta.env.NODE_ENV": '"production"', - }, - entryPoints: [entryFilePath], - bundle: false, - write: false, - }); - - return result.outputFiles[0].text; - } - - return readFileSync(filepath, "utf-8"); - }, - }); - - for (const file of fileList) { - if ( - reasons.has(file) && - reasons.get(file)?.type.includes("asset") && - !file.endsWith(".js") && - !file.endsWith(".cjs") && - !file.endsWith(".mjs") && - !file.endsWith("package.json") - ) { - const absolutePath = path.join(base, file); - - // @vercel/nft needs to scan the original entries in order to find missing assets. - // But Vite already did a pass, and assets imports can have already been rewritten. - // If so, instead of using the original filename found by @vercel/nft, - // we use the one generated by Vite. - const assetRenamedByVite = bundledAssets.get(absolutePath); - - const basename = path.basename(assetRenamedByVite ? assetRenamedByVite.fileName : absolutePath); - - if (assetRenamedByVite) { - // Edit imports in-place to make them relative - writeFileSync( - destination, - readFileSync(destination, "utf-8").replaceAll( - `/${assetRenamedByVite.fileName}`, - `./${path.basename(assetRenamedByVite.fileName)}`, - ), - ); - } - - await copyFile(absolutePath, path.join(path.dirname(destination), basename)); - } - } -} diff --git a/packages/adapter-vercel/src/plugins/clean-outdir.ts b/packages/adapter-vercel/src/plugins/clean-outdir.ts deleted file mode 100644 index 3a23171a..00000000 --- a/packages/adapter-vercel/src/plugins/clean-outdir.ts +++ /dev/null @@ -1,43 +0,0 @@ -import fs from "node:fs"; -import path from "node:path"; -import type { Plugin } from "vite"; -import type { ViteVercelConfig } from "../types"; - -export function vercelCleanupPlugin(pluginConfig?: ViteVercelConfig): Plugin { - let alreadyRun = false; - - return { - apply: "build", - name: "vite-plugin-vercel:cleanup", - enforce: "pre", - - applyToEnvironment(env) { - return env.name === "client"; - }, - - buildStart: { - order: "pre", - sequential: true, - handler() { - if (alreadyRun) return; - alreadyRun = true; - const absoluteOutdir = - pluginConfig?.outDir && path.isAbsolute(pluginConfig.outDir) - ? pluginConfig.outDir - : path.join(this.environment.config.root, pluginConfig?.outDir ?? ".vercel/output"); - cleanOutputDirectory(absoluteOutdir); - }, - }, - - sharedDuringBuild: true, - }; -} - -function cleanOutputDirectory(outdir: string) { - fs.rmSync(outdir, { - recursive: true, - force: true, - }); - - fs.mkdirSync(outdir, { recursive: true }); -} diff --git a/packages/adapter-vercel/src/plugins/index.ts b/packages/adapter-vercel/src/plugins/index.ts deleted file mode 100644 index f0f5c646..00000000 --- a/packages/adapter-vercel/src/plugins/index.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { installPhoton } from "@photonjs/runtime/vite"; -import type { ViteVercelConfig } from "../types"; -import { apiPlugin } from "./api"; -import { bundlePlugin } from "./bundle"; -import { vercelCleanupPlugin } from "./clean-outdir"; -import { loaderPlugin } from "./loader"; -import { routesPlugins } from "./routes"; -import { setupEnvs } from "./setupEnvs"; -import { wasmPlugin } from "./wasm"; - -type PluginInterop = Record & { name: string }; -export function vercel(pluginConfig: ViteVercelConfig = {}): PluginInterop[] { - const additionalConfig: Record = {}; - if (pluginConfig.entries) { - additionalConfig.entries = pluginConfig.entries; - } - if (pluginConfig.server) { - additionalConfig.server = pluginConfig.server; - } - - return [ - ...installPhoton("@photonjs/vercel", { - ...additionalConfig, - defaultBuildEnv: "vercel_node", - codeSplitting: { - target: true, - }, - devServer: { - env: "vercel_node", - }, - resolveMiddlewares(env) { - if (env === "dev") { - return "@photonjs/vercel/universal-middleware/dev"; - } - return "@photonjs/vercel/universal-middleware"; - }, - }), - vercelCleanupPlugin(), - apiPlugin(pluginConfig), - ...setupEnvs(pluginConfig), - wasmPlugin(), - ...loaderPlugin(pluginConfig), - ...routesPlugins(), - ...bundlePlugin(pluginConfig), - ] as PluginInterop[]; -} - -export default vercel; diff --git a/packages/adapter-vercel/src/plugins/loader.ts b/packages/adapter-vercel/src/plugins/loader.ts deleted file mode 100644 index 5236d612..00000000 --- a/packages/adapter-vercel/src/plugins/loader.ts +++ /dev/null @@ -1,187 +0,0 @@ -import { targetLoader } from "@photonjs/core/vite"; -import { getNodeVersion, type NodeVersion } from "@vercel/build-utils"; -import { vercelOutputPrerenderConfigSchema } from "@vite-plugin-vercel/schemas"; -import { toPathToRegexpV6 } from "convert-route/path-to-regexp-v6"; -import { fromRou3 } from "convert-route/rou3"; -import type { Plugin } from "vite"; -import { assert } from "../assert"; -import { getVcConfig } from "../build"; -import type { ViteVercelConfig } from "../types"; -import { photonEntryDestination, photonEntryDestinationDefault } from "../utils/destination"; -import { entryToPathtoregex } from "../utils/route"; - -const DUMMY = "__DUMMY__"; -const re_DUMMY = new RegExp(`${DUMMY}$`); -const nonEdgeServers = ["express", "fastify"]; - -export function loaderPlugin(pluginConfig: ViteVercelConfig): Plugin[] { - let nodeVersion: NodeVersion; - - return [ - { - name: "vite-plugin-vercel:update-entries", - apply: "build", - - buildStart: { - order: "post", - handler() { - for (const entry of [this.environment.config.photon.server, ...this.environment.config.photon.entries]) { - if (!entry.env) { - entry.env = entry.vercel?.edge ? "vercel_edge" : "vercel_node"; - } - if (entry.env === "vercel_edge" || entry.env === "vercel_node") { - entry.target = `${photonEntryDestination(entry, ".func/index")}.js`; - } - } - }, - }, - - sharedDuringBuild: true, - }, - { - name: "vite-plugin-vercel:dummy", - enforce: "pre", - - resolveId: { - filter: { - id: re_DUMMY, - }, - - handler(id) { - return id; - }, - }, - - load: { - filter: { - id: re_DUMMY, - }, - - handler() { - // console.log avoids warning "Generated an empty chunk" - return "console.log('');export default {};"; - }, - }, - }, - ...targetLoader("vercel", { - async buildStart() { - nodeVersion = await getNodeVersion(process.cwd()); - }, - - applyToEnvironment(env) { - return env.name === "vercel_node" || env.name === "vercel_edge" || env.name === "vercel_client"; - }, - - async load(_id, { meta }) { - const entry = meta; - const isEdge = Boolean(entry.vercel?.edge); - - // Server entry should be considered a default route - // FIXME - if (entry.id === this.environment.config.photon.server.id && !entry.route && !entry.vercel?.route) { - entry.route = "/**"; - } - - // Generate .vc-config.json - this.emitFile({ - type: "asset", - fileName: photonEntryDestination(entry, ".func/.vc-config.json"), - source: JSON.stringify( - // Unpredictable things happen when the extension is .mjs on edge - getVcConfig(pluginConfig, isEdge ? "index.js" : "index.mjs", { - nodeVersion, - edge: isEdge, - streaming: entry.vercel?.streaming, - }), - undefined, - 2, - ), - }); - - // Generate *.prerender-config.json when necessary - if (entry.vercel?.isr) { - this.emitFile({ - type: "asset", - fileName: photonEntryDestination(entry, ".prerender-config.json"), - source: JSON.stringify(vercelOutputPrerenderConfigSchema.parse(entry.vercel.isr), undefined, 2), - }); - } - - // Generate rewrites - if (entry.route || entry.vercel?.route) { - pluginConfig.rewrites ??= []; - // TODO create a helper - const source = - typeof entry.vercel?.route === "string" - ? `(${entry.vercel.route})` - : typeof entry.route === "string" - ? toPathToRegexpV6(fromRou3(entry.route)) - : entryToPathtoregex(entry); - pluginConfig.rewrites.push({ - enforce: entry.vercel?.enforce, - source, - destination: - typeof entry.vercel?.route === "string" - ? `/${photonEntryDestinationDefault(entry)}?__original_path=$1` - : `/${photonEntryDestinationDefault(entry)}`, - }); - - // Generate headers - if (entry.vercel?.headers) { - pluginConfig.headers ??= []; - pluginConfig.headers.push({ - source, - headers: Object.entries(entry.vercel.headers).map(([key, value]) => ({ - key, - value, - })), - }); - } - } - - const fn = isEdge ? "createEdgeHandler" : "createNodeHandler"; - const isServerEntry = entry.type === "server"; - - if (isServerEntry && entry.server && isEdge) { - // TODO dynamically import the potential module and check if it exports expected function - assert( - !nonEdgeServers.includes(entry.server), - `${entry.server} is not compatible with Vercel Edge target. Either use another server like Hono or change target to Node`, - ); - } - - // Extract server at runtime, or default to { fetch } syntax - if (isServerEntry && (!entry.server || (entry.server === "srvx" && !isEdge))) { - //language=javascript - return `import servers from "virtual:photon:resolve-from-photon:@universal-middleware/vercel/${isEdge ? "edge" : "node"}/servers"; -import fetchable from "${entry.resolvedId ?? entry.id}"; - -const serverName = fetchable?.server?.name; - -const exportDefault = serverName && serverName !== "srvx" ? - servers[serverName].${fn}(fetchable.server.app) : - { fetch: fetchable.fetch }; - -export default exportDefault; -`; - } - - const importFrom = isServerEntry - ? `@universal-middleware/vercel/${entry.server}/${isEdge ? "edge" : "node"}` - : `@universal-middleware/vercel/${isEdge ? "edge" : "node"}`; - - const exportDefault = isServerEntry - ? `export default ${fn}(handlerOrApp)` - : `export default ${fn}(() => handlerOrApp)()`; - - //language=javascript - return ` -import { ${fn} } from "virtual:photon:resolve-from-photon:${importFrom}"; -import handlerOrApp from "${entry.resolvedId ?? entry.id}"; - -${exportDefault}; -`; - }, - }), - ]; -} diff --git a/packages/adapter-vercel/src/plugins/routes.ts b/packages/adapter-vercel/src/plugins/routes.ts deleted file mode 100644 index aaa946cb..00000000 --- a/packages/adapter-vercel/src/plugins/routes.ts +++ /dev/null @@ -1,52 +0,0 @@ -import type { Photon } from "@photonjs/core"; -import type { Plugin } from "vite"; - -export function routesPlugins(): Plugin[] { - return [ - { - name: "vite-plugin-vercel:routes-dedupe", - apply: "build", - - applyToEnvironment(env) { - return env.name === "ssr"; - }, - - buildStart: { - // Ensure that this hook is executed close to last, ensuring that all plugins had time to inject their Photon entries - order: "post", - handler() { - // By default, a unique Function is necessary per env (node, edge) - // We only need to create a new function when either `isr` or `headers` is provided - const entriesEdge = this.environment.config.photon.entries.filter((e) => e.vercel?.edge); - const entriesNode = this.environment.config.photon.entries.filter((e) => !e.vercel?.edge); - const entriesToKeep = new Set(); - - const defaultEnvIsEdge = this.environment.config.photon.defaultBuildEnv === "vercel_edge"; - - for (const envEntries of defaultEnvIsEdge ? [entriesEdge] : [entriesNode]) { - for (const page of envEntries.filter( - (p) => - p.compositionMode === "isolated" || - p.vercel?.isr || - (p.vercel?.route && p.vercel?.headers !== null && p.vercel?.headers !== undefined), - )) { - entriesToKeep.add(page); - } - } - - // Keep all entries that are not targetting the defaultBuildEnv. - // This could probably be optimized, but it's simple enough for now. - for (const page of defaultEnvIsEdge ? entriesNode : entriesEdge) { - entriesToKeep.add(page); - } - - this.environment.config.photon.entries = this.environment.config.photon.entries.filter( - (e) => !e.vikeMeta || entriesToKeep.has(e), - ); - }, - }, - - sharedDuringBuild: true, - }, - ]; -} diff --git a/packages/adapter-vercel/src/plugins/setupEnvs.ts b/packages/adapter-vercel/src/plugins/setupEnvs.ts deleted file mode 100644 index 9dfe467d..00000000 --- a/packages/adapter-vercel/src/plugins/setupEnvs.ts +++ /dev/null @@ -1,268 +0,0 @@ -import { cp } from "node:fs/promises"; -import path from "node:path"; -import type { OutputBundle } from "rollup"; -import stripAnsi from "strip-ansi"; -import { - BuildEnvironment, - createLogger, - createRunnableDevEnvironment, - type EnvironmentOptions, - mergeConfig, - type Plugin, -} from "vite"; -import { getConfig } from "../config"; -import type { ViteVercelConfig } from "../types"; -import { virtualEntry } from "../utils/const"; -import { edgeConditions } from "../utils/edge"; -import { edgeExternal } from "../utils/external"; - -const outDir = path.posix.join(process.cwd(), ".vercel/output"); -const DUMMY = "__DUMMY__"; - -export function setupEnvs(pluginConfig: ViteVercelConfig): Plugin[] { - return [ - { - name: "vite-plugin-vercel:setup-envs", - - buildApp: { - order: "post", - async handler(builder) { - try { - await builder.build(builder.environments.vercel_client); - } catch (e) { - if (e instanceof Error && e.message.includes(`Could not resolve entry module "index.html"`)) { - // ignore error - } else { - throw e; - } - } - await builder.build(builder.environments.vercel_edge); - await builder.build(builder.environments.vercel_node); - }, - }, - - config() { - const outDirOverride: EnvironmentOptions = pluginConfig.outDir - ? { - build: { - outDir: path.posix.join(pluginConfig.outDir, "_tmp"), - }, - } - : {}; - - // rollup inputs are computed by the bundle plugin dynamically - return { - environments: { - vercel_edge: createVercelEnvironmentOptions(outDirOverride), - vercel_node: createVercelEnvironmentOptions(outDirOverride), - vercel_client: { - build: { - outDir: path.join(pluginConfig.outDir ?? outDir, "static"), - copyPublicDir: true, - rollupOptions: { - input: getDummyInput(), - }, - }, - consumer: "client", - }, - }, - customLogger: createVercelLogger(), - // Required for environments to be taken into account - builder: {}, - }; - }, - - sharedDuringBuild: true, - }, - { - name: "vite-plugin-vercel:setup-envs:vercel_edge", - applyToEnvironment(env) { - return env.name === "vercel_edge"; - }, - - configEnvironment(name, config, env) { - if (name !== "vercel_edge") return; - - const isDev = env.command === "serve"; - // In dev, we're running on node, so we do not apply edge conditions - const conditions = !isDev - ? { - conditions: edgeConditions, - } - : {}; - - return { - resolve: { - external: edgeExternal, - ...conditions, - }, - build: { - target: "es2022", - rollupOptions: { - input: {}, - treeshake: "smallest", - }, - }, - optimizeDeps: { - ...config.optimizeDeps, - esbuildOptions: { - target: "es2022", - format: "esm", - }, - }, - }; - }, - - generateBundle: { - order: "post", - async handler(_opts, bundle) { - cleanupDummy(bundle); - }, - }, - - sharedDuringBuild: true, - }, - { - name: "vite-plugin-vercel:setup-envs:vercel_node", - applyToEnvironment(env) { - return env.name === "vercel_node"; - }, - - configEnvironment(name, config) { - if (name !== "vercel_node") return; - - return { - optimizeDeps: { - ...config.optimizeDeps, - }, - }; - }, - - generateBundle: { - order: "post", - async handler(_opts, bundle) { - cleanupDummy(bundle); - - // Generate config.json - this.emitFile({ - type: "asset", - fileName: "config.json", - source: JSON.stringify(getConfig(pluginConfig), undefined, 2), - }); - }, - }, - - sharedDuringBuild: true, - }, - { - name: "vite-plugin-vercel:setup-envs:vercel_client", - applyToEnvironment(env) { - return env.name === "vercel_client"; - }, - - generateBundle: { - async handler(_opts, bundle) { - cleanupDummy(bundle); - - const topLevelConfig = this.environment.getTopLevelConfig(); - const clientEnv = topLevelConfig.environments.client; - if (clientEnv) { - await cp(path.join(topLevelConfig.root, clientEnv.build.outDir), this.environment.config.build.outDir, { - recursive: true, - force: true, - dereference: true, - }); - } - }, - }, - - sharedDuringBuild: true, - }, - ]; -} - -function createVercelLogger() { - const logger = createLogger(); - const loggerInfo = logger.info; - - logger.info = (msg, options) => { - if ( - options?.environment && - (msg.includes("building for production") || msg.includes("building SSR bundle for production")) - ) { - return loggerInfo(`${msg} ${options.environment}`, options); - } - if (msg.includes(".vercel/output/_tmp")) { - const strippedMsg = stripAnsi(msg); - if ( - strippedMsg.includes(".vercel/output/_tmp/assets") || - strippedMsg.includes(".vercel/output/_tmp/chunks") || - strippedMsg.includes(".vercel/output/_tmp/entries") - ) - return; - if ( - !strippedMsg.includes(".vercel/output/_tmp/functions/") && - !strippedMsg.includes(".vercel/output/_tmp/config.json") - ) { - return; - } - return loggerInfo(msg.replace(".vercel/output/_tmp/", ".vercel/output/"), options); - } - - loggerInfo(msg, options); - }; - - return logger; -} - -function createVercelEnvironmentOptions(overrides?: EnvironmentOptions): EnvironmentOptions { - return mergeConfig( - { - // The bundle generated by esbuild takes care of this - // resolve: { - // noExternal: true, - // }, - dev: { - async createEnvironment(name, config) { - return createRunnableDevEnvironment(name, config); - }, - }, - build: { - createEnvironment(name, config) { - return new BuildEnvironment(name, config); - }, - outDir: path.posix.join(outDir, "_tmp"), - copyPublicDir: false, - rollupOptions: { - input: getDummyInput(), - output: { - sanitizeFileName: false, - sourcemap: false, - }, - }, - target: "es2022", - emptyOutDir: false, - emitAssets: true, - }, - - consumer: "server", - - keepProcessEnv: true, - } satisfies EnvironmentOptions, - overrides ?? {}, - ); -} - -function getDummyInput(): Record { - // Workaround to be able to have a complete build process even without entries. - // __DUMMY__ is deleted from the bundle before being written. - return { [DUMMY]: `${virtualEntry}:${DUMMY}` }; -} - -function cleanupDummy(bundle: OutputBundle) { - // Vite usually replaces __ by _ - const dummy = Object.keys(bundle).find((key) => key.includes("_DUMMY_")); - if (dummy) { - delete bundle[dummy]; - } -} diff --git a/packages/adapter-vercel/src/plugins/wasm.ts b/packages/adapter-vercel/src/plugins/wasm.ts deleted file mode 100644 index 2f88f49b..00000000 --- a/packages/adapter-vercel/src/plugins/wasm.ts +++ /dev/null @@ -1,26 +0,0 @@ -import type { Plugin } from "vite"; - -/** - * .wasm?module files should only be imported on Vercel's Cloud Edge environment. - * If imported locally or anywhere else, it means that packages resolution (based on `exports`) is incorrect. - * .wasm?module is replaced by Vercel when deploying in Edge (and is the only way to load actual wasm files there). - */ -export function wasmPlugin(): Plugin { - return { - name: "vite-plugin-vercel:fix-wasm-module", - enforce: "pre", - - resolveId: { - order: "pre", - async handler(id) { - if (!id.endsWith(".wasm?module")) return; - if (this.environment.name !== "vercel_edge") return; - - return { - id, - external: true, - }; - }, - }, - }; -} diff --git a/packages/adapter-vercel/src/types.ts b/packages/adapter-vercel/src/types.ts deleted file mode 100644 index ef271d2c..00000000 --- a/packages/adapter-vercel/src/types.ts +++ /dev/null @@ -1,119 +0,0 @@ -import type { Photon } from "@photonjs/core"; -import type { Header, Redirect, Rewrite } from "@vercel/routing-utils"; -import type { VercelOutputConfig, VercelOutputPrerenderConfig } from "@vite-plugin-vercel/schemas"; - -export type ViteVercelRewrite = Rewrite & { enforce?: "pre" | "post" }; -export type ViteVercelRedirect = Redirect & { enforce?: "pre" | "post" }; - -export interface ViteVercelConfig { - /** - * How long Functions should be allowed to run for every request, in seconds. - * If left empty, default value for your plan will be used. - */ - defaultMaxDuration?: number; - /** - * Default expiration time (in seconds) for prerender functions. - * Defaults to 86400 seconds (24h). - * @see {@link https://vercel.com/docs/concepts/next.js/incremental-static-regeneration} - * @see {@link https://vercel.com/docs/build-output-api/v3#vercel-primitives/prerender-functions/configuration} - */ - expiration?: number; - /** - * @see {@link https://vercel.com/docs/projects/project-configuration#rewrites} - */ - rewrites?: ViteVercelRewrite[]; - /** - * @see {@link https://vercel.com/docs/projects/project-configuration#headers} - * @beta - */ - headers?: Header[]; - /** - * @see {@link https://vercel.com/docs/projects/project-configuration#redirects} - */ - redirects?: ViteVercelRedirect[]; - /** - * @see {@link https://vercel.com/docs/projects/project-configuration#cleanurls} - */ - cleanUrls?: boolean; - /** - * @see {@link https://vercel.com/docs/projects/project-configuration#trailingslash} - */ - trailingSlash?: boolean; - /** - * When true, the Serverless Function will stream the response to the client. - * @see {@link https://vercel.com/docs/build-output-api/v3/primitives#serverless-function-configuration} - */ - defaultSupportsResponseStreaming?: boolean; - /** - * Use `getEntriesFromFs` for mapping your filesystem routes to entries. - * If you are interfacing this plugin with a framework, entries can also be added through the Photon API - */ - entries?: Record; - /** - * TODO - */ - server?: Photon.EntryServer; - /** - * Advanced configuration to override .vercel/output/config.json - * @see {@link https://vercel.com/docs/build-output-api/v3/configuration#configuration} - * @protected - */ - config?: Partial>; - /** - * Defaults to `.vercel/output`. Mostly useful for testing purpose - * @protected - */ - outDir?: string; -} - -export interface VercelOutputIsr extends VercelOutputPrerenderConfig { - symlink?: string; - route?: string; -} - -/** - * Keys are path relative to .vercel/output/static directory - */ -export type ViteVercelRouteOverrides = VercelOutputConfig["overrides"]; - -export interface VercelEntryOptions { - /** - * Relative to `.vercel/output/functions`, without extension - */ - // TODO remove. Replaced by Photon.EntryBase['target'] - destination?: string; - /** - * If `true`, guesses route for the function, and adds it to config.json (mimics defaults Vercel behavior). - * If a string is provided, it will be equivalent to a `rewrites` rule. - * Set to `false` to disable - */ - route?: string | boolean; - /** - * Ensures that the route is added before or after others - */ - enforce?: "post" | "pre"; - /** - * Set to `true` to mark this function as an Edge Function - */ - edge?: boolean; - /** - * Additional headers - */ - headers?: Record | null; - /** - * ISR config - */ - isr?: VercelOutputIsr; - /** - * When true, the Serverless Function will stream the response to the client - */ - streaming?: boolean; -} - -declare module "@photonjs/core" { - export namespace Photon { - export interface EntryBase { - vercel?: VercelEntryOptions; - } - } -} diff --git a/packages/adapter-vercel/src/utils/const.ts b/packages/adapter-vercel/src/utils/const.ts deleted file mode 100644 index 9410ace1..00000000 --- a/packages/adapter-vercel/src/utils/const.ts +++ /dev/null @@ -1 +0,0 @@ -export const virtualEntry = "virtual:vite-plugin-vercel:entry"; diff --git a/packages/adapter-vercel/src/utils/destination.ts b/packages/adapter-vercel/src/utils/destination.ts deleted file mode 100644 index c49f1069..00000000 --- a/packages/adapter-vercel/src/utils/destination.ts +++ /dev/null @@ -1,13 +0,0 @@ -import path from "node:path"; -import type { Photon } from "@photonjs/core"; - -export function photonEntryDestinationDefault(entry: Photon.EntryBase) { - return entry.vercel?.destination ?? entry.name.replace(/[^a-zA-Z0-9\-_[\]/]/g, "-"); -} - -export function photonEntryDestination( - entry: Photon.EntryBase, - postfix: `.func/index` | `.func/.vc-config.json` | `.func/package.json` | `.prerender-config.json`, -) { - return `${path.posix.join("functions/", photonEntryDestinationDefault(entry))}${postfix}`; -} diff --git a/packages/adapter-vercel/src/utils/edge.ts b/packages/adapter-vercel/src/utils/edge.ts deleted file mode 100644 index 8ba9b55d..00000000 --- a/packages/adapter-vercel/src/utils/edge.ts +++ /dev/null @@ -1 +0,0 @@ -export const edgeConditions = ["edge-light", "worker", "browser", "module", "import", "default"]; diff --git a/packages/adapter-vercel/src/utils/env.ts b/packages/adapter-vercel/src/utils/env.ts deleted file mode 100644 index f899aa76..00000000 --- a/packages/adapter-vercel/src/utils/env.ts +++ /dev/null @@ -1,6 +0,0 @@ -import type { Environment } from "vite"; - -export function isVercelLastBuildStep(env: string | Environment) { - const name = typeof env !== "string" ? env.name : env; - return name === "vercel_node"; -} diff --git a/packages/adapter-vercel/src/utils/external.ts b/packages/adapter-vercel/src/utils/external.ts deleted file mode 100644 index 41f06e7f..00000000 --- a/packages/adapter-vercel/src/utils/external.ts +++ /dev/null @@ -1,3 +0,0 @@ -// See https://vercel.com/docs/functions/runtimes/edge#compatible-node.js-modules -const _external = ["async_hooks", "events", "buffer", "assert", "util"]; -export const edgeExternal = [..._external, ..._external.map((e) => `node:${e}`)]; diff --git a/packages/adapter-vercel/src/utils/fs-entries.ts b/packages/adapter-vercel/src/utils/fs-entries.ts deleted file mode 100644 index 01abf6fe..00000000 --- a/packages/adapter-vercel/src/utils/fs-entries.ts +++ /dev/null @@ -1,92 +0,0 @@ -import path from "node:path"; -import glob from "fast-glob"; -import "../types"; -import type { Photon } from "@photonjs/core"; -import { type VercelEndpointExports, vercelEndpointExports } from "@vite-plugin-vercel/schemas"; -import { type ASTNode, generateCode, loadFile } from "magicast"; -import { normalizePath } from "vite"; -import { entryToRou3 } from "./route"; - -export async function getEntriesFromFs( - dir: string, - { destination = dir, tryParseExports = true }, -): Promise> { - const normalizedDir = normalizePath(dir); - destination = normalizePath(destination); - const apiEntries = glob - .sync(`${path.posix.resolve(normalizedDir)}/**/*.?(m)[jt]s?(x)`) - // from Vercel doc: Files with the underscore prefix are not turned into Serverless Functions. - .filter((filepath) => !path.basename(filepath).startsWith("_")); - - const entryPoints: Record = {}; - - for (const filePath of apiEntries) { - const outFilePath = pathRelativeTo(filePath, normalizedDir); - const parsed = path.posix.parse(outFilePath); - let xports: VercelEndpointExports | undefined | null; - - if (tryParseExports) { - xports = await extractExports(filePath); - } - - const key = path.posix.join(destination, parsed.dir, parsed.name); - const entry = { - id: filePath, - name: key, - type: "universal-handler", - compositionMode: "isolated", - vercel: { - route: true, - destination: key, - edge: xports?.edge, - isr: xports?.isr, - headers: xports?.headers, - streaming: xports?.streaming, - }, - } satisfies Photon.EntryUniversalHandler; - // next-fs patterns cannot generate more than one rou3 pattern, so [0] is fine - (entry as Photon.EntryUniversalHandler).route = entryToRou3(entry)[0]; - entryPoints[key] = entry; - } - - return entryPoints; -} - -export async function extractExports(filepath: string) { - try { - const mod = await loadFile(filepath); - - const subject = { - edge: evalExport(mod.exports.edge), - headers: evalExport(mod.exports.headers), - streaming: evalExport(mod.exports.streaming), - isr: evalExport(mod.exports.isr), - }; - - return vercelEndpointExports.parse(subject); - } catch (e) { - console.warn(`Warning: failed to read exports of '${filepath}'`, e); - return null; - } -} - -function pathRelativeTo(filePath: string, rel: string): string { - return normalizePath(path.relative(normalizePath(path.resolve(rel)), path.resolve(filePath))); -} - -function isPrimitive(test: unknown) { - return test !== Object(test); -} - -function _eval(code: unknown): boolean { - const func = new Function(`{ return function(){ return ${code} } };`); - return func.call(null).call(null); -} - -function evalExport(exp: unknown) { - if (!exp) return; - - const code = isPrimitive(exp) ? exp : generateCode(exp as ASTNode).code; - - return _eval(code); -} diff --git a/packages/adapter-vercel/src/utils/index.ts b/packages/adapter-vercel/src/utils/index.ts deleted file mode 100644 index 5ea73b05..00000000 --- a/packages/adapter-vercel/src/utils/index.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { extractExports, getEntriesFromFs } from "./fs-entries"; -export { getOriginalRequest } from "./original-request"; diff --git a/packages/adapter-vercel/src/utils/original-request.ts b/packages/adapter-vercel/src/utils/original-request.ts deleted file mode 100644 index 1f19faeb..00000000 --- a/packages/adapter-vercel/src/utils/original-request.ts +++ /dev/null @@ -1,33 +0,0 @@ -export function getOriginalRequest(request: Request) { - const xNowRouteMatchesHeader = request.headers.get("x-now-route-matches"); - const originalUrl = new URL(request.url); - const originalPath = originalUrl.searchParams.get("__original_path"); - let newUrl = null; - - let newRequest = request; - - if (originalPath) { - newUrl = new URL(originalPath, request.url).toString(); - } else if (typeof xNowRouteMatchesHeader === "string") { - const originalPathBis = new URLSearchParams(xNowRouteMatchesHeader).get("1"); - if (originalPathBis) { - newUrl = new URL(originalPathBis, request.url).toString(); - } - } - - if (newUrl) { - newRequest = new Request(newUrl, { - method: request.method, - headers: request.headers, - body: request.body, - mode: request.mode, - credentials: request.credentials, - cache: request.cache, - redirect: request.redirect, - referrer: request.referrer, - integrity: request.integrity, - }); - } - - return newRequest; -} diff --git a/packages/adapter-vercel/src/utils/route.ts b/packages/adapter-vercel/src/utils/route.ts deleted file mode 100644 index 7e1e3fed..00000000 --- a/packages/adapter-vercel/src/utils/route.ts +++ /dev/null @@ -1,18 +0,0 @@ -import path from "node:path"; -import type { Photon } from "@photonjs/core"; -import { toRou3 } from "convert-route"; -import { fromNextFs } from "convert-route/next-fs"; -import { toPathToRegexpV6 } from "convert-route/path-to-regexp-v6"; -import { assert } from "../assert"; -import { photonEntryDestinationDefault } from "./destination"; - -// @vercel/routing-utils respects path-to-regexp v6 syntax -export function entryToPathtoregex(entry: Photon.EntryBase) { - assert(typeof entry.vercel?.route !== "string", "Do not pass entry with route string to entryToPathtoregex"); - return toPathToRegexpV6(fromNextFs(path.posix.resolve("/", photonEntryDestinationDefault(entry)))); -} - -export function entryToRou3(entry: Photon.EntryBase) { - assert(typeof entry.vercel?.route !== "string", "Do not pass entry with route string to entryToPathtoregex"); - return toRou3(fromNextFs(path.posix.resolve("/", photonEntryDestinationDefault(entry)))); -} diff --git a/packages/adapter-vercel/tsconfig.json b/packages/adapter-vercel/tsconfig.json deleted file mode 100644 index 22d52c4d..00000000 --- a/packages/adapter-vercel/tsconfig.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "compilerOptions": { - "target": "ES2021", - "lib": ["es2021", "dom"], - "module": "ESNext", - "esModuleInterop": true, - "forceConsistentCasingInFileNames": true, - "verbatimModuleSyntax": true, - "strict": true, - "skipLibCheck": true, - "moduleResolution": "Bundler", - "paths": { - "vite": ["./node_modules/vite"] - } - } -} diff --git a/packages/adapter-vercel/tsdown.config.ts b/packages/adapter-vercel/tsdown.config.ts deleted file mode 100644 index 670397c8..00000000 --- a/packages/adapter-vercel/tsdown.config.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { defineConfig, type UserConfig as TsdownOptions } from "tsdown"; - -const commonOptions = { - format: ["esm"], - target: "es2022", - dts: true, - outDir: "dist", - treeshake: true, - nodeProtocol: true, - fixedExtension: false, - external: [/^virtual:photon:get-middlewares:/, /^@photonjs\/core\/dev/, /^@photonjs\/vercel/], -} satisfies TsdownOptions; - -export default defineConfig([ - { - ...commonOptions, - platform: "node", - entry: { - index: "./src/index.ts", - vite: "./src/plugins/index.ts", - utils: "./src/utils/index.ts", - api: "./src/api.ts", - types: "./src/types.ts", - "universal-middleware-dev": "./src/photon/universal-middleware-dev.ts", - "universal-middleware-prod": "./src/photon/universal-middleware-prod.ts", - }, - }, -]); diff --git a/packages/core/src/api/api.ts b/packages/core/src/api/api.ts deleted file mode 100644 index 505250a8..00000000 --- a/packages/core/src/api/api.ts +++ /dev/null @@ -1,59 +0,0 @@ -import { merge } from "ts-deepmerge"; -import * as z from "zod"; -import type { PluginContext } from "../plugin/utils/rollupTypes.js"; -import type { Photon } from "../types.js"; -import { PhotonConfigError, PhotonUsageError } from "../utils/assert.js"; -import { entryToPhoton } from "../validators/coerce.js"; -import { PhotonEntryServerConfig, PhotonEntryUniversalHandler } from "../validators/validators.js"; - -/** - * Registers a new Photon entry. - * @throws {PhotonConfigError} will throw an error if an entry with this name already exists. - */ -export function addPhotonEntry(pluginContext: PluginContext, name: string, entry: Photon.EntryPartial) { - if (pluginContext.environment.config.afterBuildStart) { - throw new PhotonUsageError("Cannot use addPhotonEntry entry after buildStart hook."); - } - if (pluginContext.environment.config.photon.entries.some((e) => e.name === entry.name)) { - throw new PhotonConfigError(`Photon entry with name "${entry.name}" already exists.`); - } - - const parsed = z - .union([PhotonEntryUniversalHandler, PhotonEntryServerConfig]) - .parse(entryToPhoton("handler-entry", entry, name)); - - if (pluginContext.environment.config.photon.codeSplitting.framework && parsed.type === "server-config") { - throw new PhotonConfigError( - `Photon entry with name "${entry.name}" is of type "server-config" but code splitting is enabled. Please disable code splitting or use "universal-handler" instead.`, - ); - } - - pluginContext.environment.config.photon.entries.push(parsed); -} - -/** - * Updates an existing Photon entry. - * @throws {PhotonConfigError} will throw an error if no entry with this name already exists. - */ -export function updatePhotonEntry(pluginContext: PluginContext, name: string, entry: Photon.EntryPartial) { - const foundEntry = pluginContext.environment.config.photon.entries.find((e) => e.name === entry.name); - if (!foundEntry) { - throw new PhotonConfigError(`Photon entry with name "${entry.name}" not found.`); - } - - const parsed = z - .union([PhotonEntryUniversalHandler, PhotonEntryServerConfig]) - .parse(entryToPhoton("handler-entry", entry, name)); - - if (pluginContext.environment.config.photon.codeSplitting.framework && parsed.type === "server-config") { - throw new PhotonConfigError( - `Photon entry with name "${entry.name}" is of type "server-config" but code splitting is enabled. Please disable code splitting or use "universal-handler" instead.`, - ); - } - - Object.assign(foundEntry, merge(foundEntry, parsed)); -} - -export function getPhotonServerIdWithEntry(condition: "dev" | "node" | "edge", handlerId: string) { - return `virtual:photon:server-entry-with-entry:${condition}:${handlerId}`; -} diff --git a/packages/core/src/apply.ts b/packages/core/src/apply.ts deleted file mode 100644 index a286e121..00000000 --- a/packages/core/src/apply.ts +++ /dev/null @@ -1,124 +0,0 @@ -import { - type EnhancedMiddleware, - getUniversalProp, - nameSymbol, - type UniversalHandler, - type UniversalMiddleware, -} from "@universal-middleware/core"; -import { extractUniversal } from "./plugin/utils/universal.js"; - -function errorMessageMiddleware(_id: string, index: number) { - return `Additional middleware at index ${index} default export must respect the following type: UniversalMiddleware | UniversalMiddleware[]. Each individual middleware must be wrapped with enhance helper with at least a 'name'. See https://universal-middleware.dev/helpers/enhance`; -} - -type Apply = (app: App, middlewares: EnhancedMiddleware[]) => void; -type ApplyReturnApp = (middlewares: EnhancedMiddleware[]) => App; -type AsyncApply = (app: App, middlewares: EnhancedMiddleware[]) => Promise; - -export function createApplyReturnApp( - server: string, - applyAdapter: ApplyReturnApp, - getUniversalEntries: () => UniversalHandler[], - getUniversalMiddlewares: () => UniversalMiddleware[], - devServerMiddleware?: () => UniversalMiddleware, -) { - return function apply(additionalMiddlewares?: UniversalMiddleware[]): T { - const middlewares = getUniversalMiddlewares(); - const entries = getUniversalEntries(); - if (devServerMiddleware) { - middlewares.unshift(devServerMiddleware()); - } - - // dedupe - if (additionalMiddlewares) { - for (const middleware of extractUniversal(additionalMiddlewares, "", errorMessageMiddleware)) { - const i = middlewares.findIndex( - (m) => getUniversalProp(m, nameSymbol) === getUniversalProp(middleware, nameSymbol), - ); - if (i !== -1) { - middlewares.splice(i, 1); - } - middlewares.push(middleware); - } - } - - const app = applyAdapter([...middlewares, ...entries]); - - // biome-ignore lint/suspicious/noExplicitAny: any - (app as any)[Symbol.for("photon:server")] = server; - - return app as T; - }; -} - -export function createApply( - server: string, - applyAdapter: Apply, - getUniversalEntries: () => UniversalHandler[], - getUniversalMiddlewares: () => UniversalMiddleware[], - devServerMiddleware?: () => UniversalMiddleware, -) { - return function apply(app: T, additionalMiddlewares?: UniversalMiddleware[]): T { - const middlewares = getUniversalMiddlewares(); - const entries = getUniversalEntries(); - if (devServerMiddleware) { - middlewares.unshift(devServerMiddleware()); - } - - // dedupe - if (additionalMiddlewares) { - for (const middleware of extractUniversal(additionalMiddlewares, "", errorMessageMiddleware)) { - const i = middlewares.findIndex( - (m) => getUniversalProp(m, nameSymbol) === getUniversalProp(middleware, nameSymbol), - ); - if (i !== -1) { - middlewares.splice(i, 1); - } - middlewares.push(middleware); - } - } - - applyAdapter(app, [...middlewares, ...entries]); - - // biome-ignore lint/suspicious/noExplicitAny: any - (app as any)[Symbol.for("photon:server")] = server; - - return app; - }; -} - -export function createAsyncApply( - server: string, - applyAdapter: AsyncApply, - getUniversalEntries: () => UniversalHandler[], - getUniversalMiddlewares: () => UniversalMiddleware[], - devServerMiddleware?: () => UniversalMiddleware, -) { - return async function apply(app: T, additionalMiddlewares?: UniversalMiddleware[]): Promise { - const middlewares = getUniversalMiddlewares(); - const entries = getUniversalEntries(); - if (devServerMiddleware) { - middlewares.unshift(devServerMiddleware()); - } - - // dedupe - if (additionalMiddlewares) { - for (const middleware of extractUniversal(additionalMiddlewares, "", errorMessageMiddleware)) { - const i = middlewares.findIndex( - (m) => getUniversalProp(m, nameSymbol) === getUniversalProp(middleware, nameSymbol), - ); - if (i !== -1) { - middlewares.splice(i, 1); - } - middlewares.push(middleware); - } - } - - await applyAdapter(app, [...middlewares, ...entries]); - - // biome-ignore lint/suspicious/noExplicitAny: any - (app as any)[Symbol.for("photon:server")] = server; - - return app; - }; -} diff --git a/packages/core/src/plugin/plugins/commonConfig.ts b/packages/core/src/plugin/plugins/commonConfig.ts deleted file mode 100644 index 3b9cff27..00000000 --- a/packages/core/src/plugin/plugins/commonConfig.ts +++ /dev/null @@ -1,155 +0,0 @@ -import { builtinModules } from "node:module"; -import { defaultClientConditions, defaultExternalConditions, defaultServerConditions, type Plugin } from "vite"; -import type { Photon } from "../../types.js"; -import { resolvePhotonConfig } from "../../validators/coerce.js"; -import { SupportedServers } from "../../validators/validators.js"; -import { singleton } from "../utils/dedupe.js"; -import { isBun } from "../utils/isBun.js"; -import { isDeno } from "../utils/isDeno.js"; - -export { commonConfig }; - -function commonConfig(): Plugin[] { - let resolvedPhotonConfig: Photon.ConfigResolved; - return [ - singleton({ - name: "photon:optimize-deps", - - config: { - order: "post", - handler(userConfig) { - resolvedPhotonConfig = resolvePhotonConfig(userConfig.photon); - }, - }, - configEnvironment(name, config) { - if (!config.consumer) { - config.consumer = name === "client" ? "client" : "server"; - } - - if (config.consumer !== "server") return; - const servers = Object.keys(SupportedServers.enum); - - // Photon can replace entries with virtual modules. If so, we need to ensure that `optimizeDeps.entries` - // still points to users entries so that Vite can crawl them - const entries = [resolvedPhotonConfig.server.id, ...resolvedPhotonConfig.entries.map((e) => e.id)] - .filter(Boolean) - .map((id) => id.replace(/^virtual:photon:(handler-entry|server-entry|server-config):/, "")); - - return { - // From Vite doc: - // > If the dependency is small and is already valid ESM, - // > you can exclude it and let the browser load it directly. - // When using cloudflare, if you stumble upon the following error, you probably needs to exclude some - // dependency from optimizeDeps: "There is a new version of the pre-bundle for [...]" - optimizeDeps: { - entries, - exclude: [ - "hono", - "h3", - "srvx", - "elysia", - ...servers.map((s) => `@universal-middleware/${s}`), - "@universal-middleware/compress", - "@universal-middleware/core", - "@universal-middleware/sirv", - "@universal-middleware/cloudflare", - "@universal-middleware/vercel", - ...servers.map((s) => `@photonjs/${s}`), - "@photonjs/core", - "@photonjs/runtime", - "@photonjs/cloudflare", - "@photonjs/vercel", - ], - }, - }; - }, - }), - singleton({ - name: "photon:common-config", - - configEnvironment(name, config) { - if (!config.consumer) { - config.consumer = name === "client" ? "client" : "server"; - } - - const defaultCondition = config.consumer === "client" ? defaultClientConditions : defaultServerConditions; - - let additionalResolveConfig: { - externalConditions?: string[]; - conditions?: string[]; - noExternal?: string[]; - alias?: Record; - } = {}; - - if (isBun) { - additionalResolveConfig = { - conditions: ["bun", ...defaultCondition], - externalConditions: ["bun", ...defaultExternalConditions], - }; - } - - if (isDeno) { - additionalResolveConfig = { - conditions: ["deno", ...defaultCondition], - externalConditions: ["deno", ...defaultExternalConditions], - }; - } - - // Ensure that all native node modules start with `node:`, mostly for Deno compat - additionalResolveConfig.alias = Object.fromEntries(builtinModules.map((m) => [m, `node:${m}`])); - - // do not override `noExternal: true` - if (config.resolve?.noExternal !== true) { - additionalResolveConfig.noExternal = [ - "@photonjs/cloudflare", - "@photonjs/core", - "@photonjs/runtime", - "@photonjs/h3", - "@photonjs/elysia", - "@photonjs/hono", - "@photonjs/express", - "@photonjs/fastify", - "@photonjs/hattip", - "@photonjs/srvx", - ]; - } - - const buildTarget = config.consumer === "client" ? null : { build: { target: "es2022" } }; - - return { - resolve: { - ...additionalResolveConfig, - }, - ...buildTarget, - }; - }, - }), - singleton({ - name: "photon:set-after-build-start", - enforce: "post", - buildStart: { - order: "post", - handler() { - Object.defineProperty(this.environment.config, "afterBuildStart", { - get() { - return true; - }, - }); - }, - }, - }), - ...(isDeno - ? [ - singleton({ - name: "photon:deno-config", - enforce: "pre", - resolveId(source) { - if (builtinModules.includes(source)) { - return { id: `node:${source}`, external: true }; - } - }, - }), - ] - : []), - ]; -} diff --git a/packages/core/src/plugin/plugins/getMiddlewaresPlugin.ts b/packages/core/src/plugin/plugins/getMiddlewaresPlugin.ts deleted file mode 100644 index fd4057d1..00000000 --- a/packages/core/src/plugin/plugins/getMiddlewaresPlugin.ts +++ /dev/null @@ -1,108 +0,0 @@ -import type { Plugin } from "vite"; -import { getPhotonMeta } from "../../utils/meta.js"; -import { singleton } from "../utils/dedupe.js"; -import type { PluginContext } from "../utils/rollupTypes.js"; -import { ifPhotonModule } from "../utils/virtual.js"; - -async function getAllPhotonMiddlewares( - pluginContext: PluginContext, - condition: "dev" | "edge" | "node", - server: string, - handlerId?: string, -) { - const isDev = condition === "dev"; - const defaultBuildEnv = pluginContext.environment.config.photon.defaultBuildEnv; - const currentEnv = pluginContext.environment.name; - - const metaHandler = handlerId ? await getPhotonMeta(pluginContext, handlerId, "handler-entry") : null; - - // middlewares - const getMiddlewares = pluginContext.environment.config.photon.middlewares ?? []; - const middlewares = - metaHandler?.compositionMode === "isolated" - ? [] - : ( - await Promise.all( - getMiddlewares.map((m) => m.call(pluginContext, condition as "dev" | "node" | "edge", server)), - ) - ) - .filter((x) => typeof x === "string" || Array.isArray(x)) - .flat(1); - - // handlers - let universalEntries = pluginContext.environment.config.photon.entries.filter((e) => e.type === "universal-handler"); - if (!isDev) { - // Only inject entries for the current environment - universalEntries = universalEntries.filter((h) => (h.env || defaultBuildEnv) === currentEnv); - if (pluginContext.environment.config.photon.codeSplitting.target) { - // Do not inject isolated entries when target supports code splitting - universalEntries = universalEntries.filter((h) => h.compositionMode !== "isolated"); - } - } - const universalEntriesIds = metaHandler ? [metaHandler.id] : universalEntries.map((e) => e.id); - - //language=javascript - return ` -import { getUniversal, nameSymbol } from 'virtual:photon:resolve-from-photon:@universal-middleware/core'; -import { PhotonConfigError } from 'virtual:photon:resolve-from-photon:@photonjs/core/errors'; -${middlewares.map((m, i) => `import m${i} from ${JSON.stringify(m)};`).join("\n")} -${universalEntriesIds.map((m, i) => `import u${i} from ${JSON.stringify(m)};`).join("\n")} - -function errorMessageMiddleware(id) { - return \`"\${id}" default export must respect the following type: UniversalMiddleware | UniversalMiddleware[]. Each individual middleware must be wrapped with enhance helper. See https://universal-middleware.dev/helpers/enhance\` -} - -function errorMessageEntry(id) { - return \`"\${id}" default export must respect the following type: UniversalHandler. Make sure this entry have a route defined through Photon config or through enhance helper (https://universal-middleware.dev/helpers/enhance)\` -} - -export function extractUniversal(mi, id, errorMessage) { - return [mi] - .flat(Number.POSITIVE_INFINITY) - .map(getUniversal) - .map((m, i) => { - if (typeof m === 'function' && nameSymbol in m) { - return m; - } - throw new PhotonConfigError(errorMessage(id, i)); - } - ); -} - -export function getUniversalMiddlewares() { - return [${middlewares.map((m, i) => `extractUniversal(m${i}, ${JSON.stringify(m)}, errorMessageMiddleware)`).join(", ")}].flat(1); -} - -export function getUniversalEntries() { - return [${universalEntriesIds.map((m, i) => `extractUniversal(u${i}, ${JSON.stringify(m)}, errorMessageEntry)`).join(", ")}].flat(1); -} -`; -} - -export function getMiddlewaresPlugin(): Plugin[] { - return [ - singleton({ - name: "photon:get-middlewares", - - async resolveId(id, _importer, opts) { - return ifPhotonModule("get-middlewares", id, () => ({ - id, - moduleSideEffects: false, - meta: { - // opts.attributes can be undefined with rolldown-vite - photonHandler: opts.attributes?.photonHandler, - }, - })); - }, - - load(id) { - return ifPhotonModule("get-middlewares", id, async ({ condition, server, handler }) => { - return { - code: await getAllPhotonMiddlewares(this, condition as "dev" | "edge" | "node", server, handler), - map: { mappings: "" } as const, - }; - }); - }, - }), - ]; -} diff --git a/packages/core/src/plugin/plugins/installPhoton.ts b/packages/core/src/plugin/plugins/installPhoton.ts deleted file mode 100644 index b7eae6fa..00000000 --- a/packages/core/src/plugin/plugins/installPhoton.ts +++ /dev/null @@ -1,189 +0,0 @@ -import type { Plugin } from "vite"; -import type { GetPhotonCondition } from "../../validators/types.js"; -import { resolveFirst } from "../utils/resolve.js"; -import type { PluginContext } from "../utils/rollupTypes.js"; -import { ifPhotonModule } from "../utils/virtual.js"; - -export interface InstallPhotonBaseOptions { - resolveMiddlewares?: GetPhotonCondition; -} - -export function simplePhotonResolver(): Plugin { - return { - name: `photon:resolve-from-photon`, - enforce: "pre", - - resolveId(id, importer, opts) { - return ifPhotonModule("resolve-from-photon", id, async ({ module: actualId }) => { - const foundPhotonRuntime = await resolveFirst(this, [ - { source: "@photonjs/runtime", importer: undefined, opts }, - { source: "@photonjs/runtime", importer, opts }, - ]); - - if (foundPhotonRuntime) { - const resolved = await this.resolve(actualId, foundPhotonRuntime.id, opts); - if (resolved) { - return resolved; - } - } - - const foundPhotonCore = await resolveFirst( - this, - [ - { source: "@photonjs/core", importer: undefined, opts }, - { source: "@photonjs/core", importer, opts }, - foundPhotonRuntime ? { source: "@photonjs/core", importer: foundPhotonRuntime.id, opts } : null, - ].filter(Boolean), - ); - - if (foundPhotonCore) { - return this.resolve(actualId, foundPhotonCore.id, opts); - } - }); - }, - - sharedDuringBuild: true, - }; -} - -export function installPhotonResolver(name: string, options?: InstallPhotonBaseOptions): Plugin[] { - let resolvedName: Awaited>; - - function photonVirtualModuleResolver( - id: string, - importer?: string, - opts?: { - attributes?: Record; - custom?: Record; - isEntry?: boolean; - skipSelf?: boolean; - }, - ) { - return async function resolvePhotonVirtualModule(this: Pick) { - // first, try basic resolve - let resolved = await this.resolve(id, importer, opts); - - if (resolved) { - return resolved; - } - - resolvedName ??= await resolveFirst(this, [ - { source: name, importer: undefined }, - { source: name, importer }, - ]); - - // Multiple libs can try to resolve this - if (resolvedName) { - // next, try to resolve from `name` - resolved = await this.resolve(id, resolvedName.id, opts); - - if (resolved) { - return resolved; - } - } - - // finally, fallback to finding photon and trying to resolve from there - return this.resolve(`virtual:photon:resolve-from-photon:${id}`, importer, { - ...opts, - custom: { - ...opts?.custom, - photonScope: name, - }, - }); - }; - } - - const plugins: Plugin[] = [ - // Vite node modules resolution is not on par with node, so we have to help it resolve some modules - { - name: `photon:resolve-from-photon:${name}`, - enforce: "pre", - - resolveId(id, importer, opts) { - return ifPhotonModule("resolve-from-photon", id, async ({ module: actualId }) => { - if (opts.custom?.photonScope !== undefined && opts.custom.photonScope !== name) return; - - const isLog = name === "@photonjs/vercel"; - - resolvedName ??= await resolveFirst(this, [ - { source: name, importer: undefined }, - { source: name, importer }, - ]); - - if (resolvedName && isLog) { - const resolved = await this.resolve(actualId, resolvedName.id, opts); - if (resolved) { - return resolved; - } - } - - const foundPhotonRuntime = await resolveFirst(this, [ - { source: "@photonjs/runtime", importer: undefined, opts }, - resolvedName ? { source: "@photonjs/runtime", importer: resolvedName.id, opts } : undefined, - ]); - - if (foundPhotonRuntime) { - const resolved = await this.resolve(actualId, foundPhotonRuntime.id, opts); - if (resolved) { - return resolved; - } - } - - const foundPhotonCore = await resolveFirst(this, [ - { source: "@photonjs/core", importer: undefined, opts }, - resolvedName ? { source: "@photonjs/core", importer: resolvedName.id, opts } : undefined, - ]); - - if (foundPhotonCore) { - return this.resolve(actualId, foundPhotonCore.id, opts); - } - }); - }, - - sharedDuringBuild: true, - }, - { - name: `photon:resolve-virtual-module:${name}`, - - async resolveId(id, importer, opts) { - return ifPhotonModule( - ["fallback-entry", "get-middlewares"], - id, - photonVirtualModuleResolver(id, importer, opts).bind(this), - ); - }, - - sharedDuringBuild: true, - }, - { - name: `photon:resolve-virtual-importer:${name}`, - - async resolveId(id, importer, opts) { - return ifPhotonModule( - ["fallback-entry", "get-middlewares"], - importer, - photonVirtualModuleResolver(id, importer, opts).bind(this), - ); - }, - - sharedDuringBuild: true, - }, - ]; - - if (options?.resolveMiddlewares) { - plugins.push({ - name: `photon:define-middlewares:${name}`, - config() { - if (options?.resolveMiddlewares) { - return { - photon: { - middlewares: [options.resolveMiddlewares], - }, - }; - } - }, - }); - } - - return plugins; -} diff --git a/packages/core/src/plugin/plugins/mirrorMeta.ts b/packages/core/src/plugin/plugins/mirrorMeta.ts deleted file mode 100644 index 3fcd6591..00000000 --- a/packages/core/src/plugin/plugins/mirrorMeta.ts +++ /dev/null @@ -1,172 +0,0 @@ -import { getUniversalProp, pathSymbol } from "@universal-middleware/core"; -import { walk } from "estree-walker"; -import MagicString from "magic-string"; -import { createRunnableDevEnvironment, type Plugin, type RunnableDevEnvironment } from "vite"; -import { assert, assertUsage } from "../../utils/assert.js"; -import { createDeferred } from "../../utils/deferred.js"; -import { singleton } from "../utils/dedupe.js"; -import { isPhotonMeta, type PhotonMeta } from "../utils/entry.js"; - -export function mirrorMeta(): Plugin[] { - let lastSsr: Promise | undefined; - return [ - // Extract Universal Middleware metadata and add them to Photon meta - singleton({ - name: "photon:runtime-meta-to-photon", - enforce: "pre", - apply: "build", - - config() { - return { - environments: { - inline_ssr: {}, - }, - }; - }, - - async moduleParsed(info) { - // Import the module in RunnableDevEnvironment during build to extract exports - if (isPhotonMeta(info.meta) && info.meta.photon.type === "universal-handler" && !info.meta.photon.route) { - const ssr = lastSsr - ? await lastSsr - : createRunnableDevEnvironment("inline_ssr", this.environment.config, { - runnerOptions: { - hmr: { - logger: false, - }, - }, - hot: false, - }); - if (!lastSsr) { - const deferred = createDeferred(); - lastSsr = deferred.promise; - await ssr.init(); - deferred.resolve(ssr); - } - - try { - const mod = await ssr.runner.import(info.id); - if (mod && "default" in mod) { - const def = await mod.default; - const route = getUniversalProp(def, pathSymbol); - - // Attached extracted runtime metadata to photon meta - if (route) { - info.meta.photon.route = route; - } - } - } finally { - // await ssr.runner.close() - } - } - }, - - async buildEnd() { - if (lastSsr && !(await lastSsr).runner.isClosed()) { - return (await lastSsr).runner.close(); - } - }, - - sharedDuringBuild: true, - }), - // Extract Photon meta of an entry, and apply them to runtime through enhance - singleton({ - name: "photon:photon-meta-to-runtime", - - applyToEnvironment(env) { - return !env.name.includes("inline_ssr"); - }, - - transform(code, id) { - const info = this.getModuleInfo(id); - if (!info) return; - - if (isPhotonMeta(info.meta) && info.meta.photon.route && info.meta.photon.type === "universal-handler") { - const ast = this.parse(code); - - const magicString = new MagicString(code); - let hasExportDefault = false; - let hasEnhanceImport = false; - - walk(ast, { - enter(node) { - if ( - !hasEnhanceImport && - node.type === "ImportDeclaration" && - typeof node.source.value === "string" && - node.source.value.includes("@universal-middleware/core") - ) { - // Check if enhance is among the imported specifiers - for (const specifier of node.specifiers) { - if ( - (specifier.type === "ImportSpecifier" && - specifier.imported && - "name" in specifier.imported && - specifier.imported.name === "enhance") || - (specifier.type === "ImportDefaultSpecifier" && specifier.local.name === "enhance") - ) { - hasEnhanceImport = true; - } - } - } - - if (node.type === "ExportAllDeclaration") { - if (node.exported && "name" in node.exported && node.exported.name === "default") { - hasExportDefault = true; - // TODO - assertUsage(false, `Entry ${id}: export { ... as default } is not yet supported`); - } - } - if (node.type === "ExportDefaultDeclaration") { - hasExportDefault = true; - - // biome-ignore lint/suspicious/noExplicitAny: any - const declarationStart: number = (node.declaration as any).start; - // biome-ignore lint/suspicious/noExplicitAny: any - const declarationEnd: number = (node.declaration as any).end; - - assert(declarationStart); - assert(declarationEnd); - - // Replace the declaration with enhance call - magicString.overwrite( - declarationStart, - declarationEnd, - `enhance(${code.slice(declarationStart, declarationEnd)}, { - name: ${JSON.stringify(id)}, - method: ['GET', 'POST'], - path: ${JSON.stringify(info.meta.photon.route)}, - context: ${JSON.stringify({ photon: photonMetaAsContext(info.meta.photon) })}, - immutable: false -})`, - ); - } - }, - }); - - assertUsage(hasExportDefault, `Entry ${id} must have a default export`); - - if (!hasEnhanceImport) { - magicString.prepend( - `import { enhance } from 'virtual:photon:resolve-from-photon:@universal-middleware/core';\n`, - ); - } - - if (!magicString.hasChanged()) return; - - return { - code: magicString.toString(), - map: magicString.generateMap(), - }; - } - }, - - sharedDuringBuild: true, - }), - ]; -} - -function photonMetaAsContext(photonMeta: PhotonMeta) { - const { id: _, resolvedId: __, ...photonMetaClean } = photonMeta; - return photonMetaClean; -} diff --git a/packages/core/src/plugin/plugins/photonEntry.ts b/packages/core/src/plugin/plugins/photonEntry.ts deleted file mode 100644 index 6366fe47..00000000 --- a/packages/core/src/plugin/plugins/photonEntry.ts +++ /dev/null @@ -1,332 +0,0 @@ -import { walk } from "estree-walker"; -import MagicString from "magic-string"; -import type { Plugin } from "vite"; -import { assert, assertUsage } from "../../utils/assert.js"; -import { singleton } from "../utils/dedupe.js"; -import { importsToServer } from "../utils/servers.js"; -import { asPhotonEntryId, ifPhotonModule, virtualModules, virtualModulesRegex } from "../utils/virtual.js"; - -const serverImports = new Set(Object.keys(importsToServer)); -const re_photonHandler = /[?&]photonHandler=/; - -function cleanImport(imp: string) { - const s = "virtual:photon:resolve-from-photon:"; - return imp.startsWith(s) ? imp.slice(s.length) : imp; -} - -export function photonEntry(): Plugin[] { - return [ - singleton({ - name: "photon:resolve-importer", - enforce: "pre", - - resolveId: { - order: "post", - handler(id, importer, opts) { - return ifPhotonModule(["handler-entry", "server-entry"], importer, ({ entry }) => { - if (entry) { - return this.resolve(id, entry, { - ...opts, - skipSelf: false, - }); - } - }); - }, - }, - sharedDuringBuild: true, - }), - singleton({ - name: "photon:resolve-server-with-entry", - enforce: "pre", - - resolveId: { - filter: { - id: virtualModulesRegex["server-entry-with-entry"], - }, - order: "post", - handler(id) { - return ifPhotonModule("server-entry-with-entry", id, async ({ entry }) => { - const handlerOrConfig = this.environment.config.photon.entries.find((e) => e.name === entry); - assertUsage(handlerOrConfig, `Unable to find entry "${entry}"`); - - return { - id, - meta: { - photon: { - ...this.environment.config.photon.server, - // Additional handler meta take precedence - ...handlerOrConfig, - type: "server", - id, - resolvedId: id, - }, - }, - resolvedBy: "photon", - }; - }); - }, - }, - - load: { - filter: { - id: virtualModulesRegex["server-entry-with-entry"], - }, - handler(id) { - return ifPhotonModule("server-entry-with-entry", id, async ({ entry }) => { - const resolved = await this.resolve(this.environment.config.photon.server.id); - assert(resolved); - - const loaded = await this.load({ id: resolved.id }); - assert(loaded.code); - - const handlerOrConfig = this.environment.config.photon.entries.find((e) => e.name === entry); - assert(handlerOrConfig); - - const code = loaded.code; - - // All entries are bundled in server-config entries - if (handlerOrConfig.type === "server-config") { - return { code }; - } - - const ast = this.parse(code); - const magicString = new MagicString(code); - - walk(ast, { - enter(node) { - if ( - node.type === "ImportDeclaration" && - typeof node.source.value === "string" && - serverImports.has(cleanImport(node.source.value)) - ) { - let foundApply = false; - // Check if { apply } is among the imported specifiers - for (const specifier of node.specifiers) { - if ( - specifier.type === "ImportSpecifier" && - specifier.imported && - "name" in specifier.imported && - specifier.imported.name === "apply" - ) { - foundApply = true; - break; - } - } - if (foundApply) { - const { end } = node.source as unknown as { start: number; end: number }; - - // Adding a query parameter that will be used to rewrite `photon:get-middlewares` imports - magicString.appendRight(end - 1, `?${new URLSearchParams({ photonHandler: entry }).toString()}`); - } - } - }, - }); - - if (!magicString.hasChanged()) return; - - return { - code: magicString.toString(), - map: magicString.generateMap(), - }; - }); - }, - }, - - sharedDuringBuild: true, - }), - singleton({ - name: "photon:transform-get-middlewares-import", - enforce: "pre", - - resolveId: { - filter: { - id: re_photonHandler, - }, - async handler(id, importer, opts) { - const [actualId, query] = id.split("?"); - // biome-ignore lint/style/noNonNullAssertion: ensured by regex - const resolved = await this.resolve(actualId!, importer, opts); - assert(resolved); - - return { - id: `${resolved.id}?${query}`, - resolvedBy: "photon", - }; - }, - }, - - load: { - filter: { - id: re_photonHandler, - }, - async handler(id) { - const [actualId, query] = id.split("?"); - // biome-ignore lint/style/noNonNullAssertion: ensured by regex - const loaded = await this.load({ id: actualId! }); - assert(loaded.code); - - const handlerId = new URLSearchParams(query).get("photonHandler"); - assert(handlerId); - - const newCode = loaded.code - // Forward query parameters to apply imports - .replace(/@photonjs\/core\/([^/]+)\/apply/, `@photonjs/core/$1/apply?${query}`) - .replace(/@photonjs\/([^/]+)\/apply/, `@photonjs/$1/apply?${query}`) - // Transform get-middleware import - .replace(/virtual:photon:get-middlewares:(.+?):(\w+)/, `virtual:photon:get-middlewares:$1:$2:${handlerId}`); - - return { - code: newCode, - map: { mappings: "" }, - }; - }, - }, - }), - singleton({ - name: "photon:resolve-server", - enforce: "pre", - - resolveId: { - filter: { - id: virtualModulesRegex["server-entry"], - }, - order: "post", - handler(id, _importer, opts) { - return ifPhotonModule("server-entry", id, async ({ entry: actualId }) => { - const entry = this.environment.config.photon.server; - - if (!actualId) { - const match = virtualModules["server-entry"].match(this.environment.config.photon.server.id); - if (match?.entry) { - actualId = match.entry; - } - } - - if (!actualId) { - return this.resolve(this.environment.config.photon.server.id, undefined, { - custom: { - setPhotonMeta: entry, - }, - }); - } - - const resolved = await this.resolve(actualId, undefined, { - ...opts, - skipSelf: false, - custom: { - setPhotonMeta: entry, - }, - }); - - assertUsage(resolved, `Cannot resolve ${actualId} to a server entry`); - - entry.resolvedId = resolved.id; - - // Ensure early resolution of photon meta during build - if (this.environment.config.command === "build") { - await this.load({ ...resolved, resolveDependencies: true }); - } - - return { - ...resolved, - meta: { - photon: entry, - }, - resolvedBy: "photon", - }; - }); - }, - }, - sharedDuringBuild: true, - }), - singleton({ - name: "photon:resolve-handler", - enforce: "pre", - - resolveId: { - filter: { - id: virtualModulesRegex["handler-entry"], - }, - order: "post", - handler(id, _importer, opts) { - return ifPhotonModule("handler-entry", id, async ({ entry: actualId }) => { - const idWithPhotonPrefix = asPhotonEntryId(id, "handler-entry"); - const handlers = this.environment.config.photon.entries.filter((e) => e.type === "universal-handler"); - let entry = handlers.find((e) => asPhotonEntryId(e.id, "handler-entry") === idWithPhotonPrefix); - - let resolved = await this.resolve(actualId, undefined, { - ...opts, - skipSelf: false, - custom: { - setPhotonMeta: entry, - }, - }); - - // Try to resolve by handler name - if (!resolved) { - const handler = handlers.find((e) => e.name === actualId); - if (handler) { - resolved = await this.resolve(handler.id, undefined, { - ...opts, - skipSelf: false, - custom: { - setPhotonMeta: entry, - }, - }); - } - } - - assertUsage(resolved, `Cannot resolve ${actualId} to a handler entry`); - - if (!entry) { - const resolvedIdWithPhotonPrefix = asPhotonEntryId(resolved.id, "handler-entry"); - entry = handlers.find((e) => { - if (e.resolvedId) { - return e.resolvedId === resolved.id; - } - return e.id === resolvedIdWithPhotonPrefix; - }); - } - - assertUsage(entry, `Cannot find a handler for ${resolved.id}`); - entry.resolvedId = resolved.id; - - // Ensure early resolution of photon meta during build - if (this.environment.config.command === "build") { - await this.load({ ...resolved, resolveDependencies: true }); - } - - return { - ...resolved, - meta: { - photon: entry, - }, - resolvedBy: "photon", - }; - }); - }, - }, - sharedDuringBuild: true, - }), - singleton({ - name: "photon:trickle-meta", - enforce: "pre", - - async resolveId(id, imports, opts) { - if (opts.custom?.setPhotonMeta) { - const resolved = await this.resolve(id, imports, opts); - - if (!resolved) return; - - return { - ...resolved, - meta: { - ...resolved.meta, - photon: opts.custom.setPhotonMeta, - }, - }; - } - }, - }), - ]; -} diff --git a/packages/core/src/plugin/plugins/resolvePhotonConfigPlugin.ts b/packages/core/src/plugin/plugins/resolvePhotonConfigPlugin.ts deleted file mode 100644 index 6c2e6155..00000000 --- a/packages/core/src/plugin/plugins/resolvePhotonConfigPlugin.ts +++ /dev/null @@ -1,74 +0,0 @@ -import { yellow } from "ansis"; -import type { Plugin } from "vite"; -import type { Photon } from "../../types.js"; -import { PhotonConfigError } from "../../utils/assert.js"; -import { resolvePhotonConfig } from "../../validators/coerce.js"; -import { singleton } from "../utils/dedupe.js"; - -let resolvedPhotonConfig: Photon.ConfigResolved | null = null; -export function resolvePhotonConfigPlugin(pluginConfig?: Photon.Config): Plugin[] { - const plugins: Plugin[] = [ - singleton({ - name: "photon:resolve-config", - enforce: "pre", - - config: { - order: "pre", - handler() { - return { - photon: [], - }; - }, - }, - - configResolved: { - order: "pre", - handler(config) { - // Ensures that a unique photon config exists across all envs - if (resolvedPhotonConfig === null) { - if (Array.isArray(config.photon.entries)) { - // If `entries` is already an Array, it means that `config.photon` is already resolved, - // most probably because another version of this plugin is installed. - console.warn( - yellow( - "[photon] Multiple versions of @photonjs/core detected. This may cause unexpected behavior. Try running 'npm dedupe' or 'yarn dedupe' to resolve version conflicts.", - ), - ); - resolvedPhotonConfig = config.photon; - } else { - // biome-ignore lint/suspicious/noExplicitAny: any - resolvedPhotonConfig = resolvePhotonConfig(config.photon as any); - } - } - if (resolvedPhotonConfig.codeSplitting.framework) { - const serverConfigEntries = resolvedPhotonConfig.entries.filter((e) => e.type === "server-config"); - if (serverConfigEntries.length > 0) { - throw new PhotonConfigError( - "server-config entries are not supported when codeSplitting.framework is true. Please disable code splitting or remove server-config entries.", - ); - } - } - config.photon = resolvedPhotonConfig; - }, - }, - }), - ]; - - if (pluginConfig) { - plugins.push({ - name: "photon:manual-config", - enforce: "pre", - - config: { - order: "pre", - handler() { - return { - photon: [pluginConfig], - }; - }, - }, - }); - } - - return plugins; -} diff --git a/packages/core/src/plugin/plugins/supportedServers.ts b/packages/core/src/plugin/plugins/supportedServers.ts deleted file mode 100644 index 15568b73..00000000 --- a/packages/core/src/plugin/plugins/supportedServers.ts +++ /dev/null @@ -1,20 +0,0 @@ -import type { Plugin } from "vite"; -import type { SupportedServers } from "../../validators/types.js"; -import { importsToServer } from "../utils/servers.js"; - -export function supportedTargetServers(name: string, servers: SupportedServers[], recommend = "hono"): Plugin { - const serversSet = new Set(servers); - - return { - name: `photon:unsupported-servers:${name}`, - enforce: "pre", - - resolveId(id) { - if (importsToServer[id] && !serversSet.has(importsToServer[id])) { - this.error( - `[photon][${name}] \`${importsToServer[id]}\` is not supported while targetting \`${name}\`. We recommend using \`${recommend}\` instead.`, - ); - } - }, - }; -} diff --git a/packages/core/src/plugin/plugins/targetLoader.ts b/packages/core/src/plugin/plugins/targetLoader.ts deleted file mode 100644 index 93c14ffa..00000000 --- a/packages/core/src/plugin/plugins/targetLoader.ts +++ /dev/null @@ -1,169 +0,0 @@ -import type { Plugin } from "vite"; -import { getPhotonServerIdWithEntry } from "../../api/api.js"; -import type { Photon } from "../../types.js"; -import { getPhotonMeta } from "../../utils/meta.js"; -import { escapeStringRegexp } from "../utils/escapeStringRegexp.js"; -import type { LoadResult, PluginContext } from "../utils/rollupTypes.js"; - -type LoadHook = ( - this: PluginContext, - id: string, - options: { - meta: Photon.EntryServer; - ssr?: boolean; - }, -) => Promise | LoadResult; - -type PluginInterop = Record & { name: string }; - -/** - * Create plugins that will emit deployment target files. - * A custom `load` hook needs to be provided. The generated code will need to: - * - Load the module pointed by `id` - * - Create the necessary code that is required by the target, wrapping and calling loaded module - * - * @see Cloudflare adapter for usage - * - * @param name Target's name, i.e. "cloudflare" - * @param options The `load` hook - */ -export function targetLoader>( - name: string, - options: T, -): PluginInterop[] { - const prefix = `virtual:photon:${name}`; - const re_prefix = new RegExp(`^${escapeStringRegexp(prefix)}:`); - - return [ - { - name: `photon:target-loader:${name}:config`, - enforce: "pre", - config() { - return { - photon: { - target: name, - }, - }; - }, - - configResolved: { - order: "post", - handler(config) { - // the target defined above has been overridden, so we do not update conditions - if (config.photon.target !== name) return; - // Remove 'node' for exports conditions when using targetLoader - const conditions = config.environments[config.photon.defaultBuildEnv]?.resolve?.conditions; - if (conditions) { - const index = conditions.indexOf("node"); - if (index !== -1) { - conditions.splice(index, 1); - } - } - }, - }, - - sharedDuringBuild: true, - }, - { - name: `photon:target-loader:${name}:emit`, - - apply: "build", - enforce: "post", - - // Any entry added after this hook will be ignored - // TODO add warnings, but be careful, as entries can be added later to be emitted by other environments - buildStart: { - order: "post", - handler() { - const envName = this.environment.name; - const photon = this.environment.config.photon; - const isEdge = this.environment.config.resolve.conditions.some((x) => - ["edge-light", "worker", "workerd", "edge"].includes(x), - ); - - if (photon.defaultBuildEnv === envName && photon.emitEntry) { - // Emit default server entry - this.emitFile({ - type: "chunk", - fileName: ensureExtension(photon.server.target || photon.server.name), - id: `${prefix}:virtual:photon:server-entry`, - }); - } - - // Emit server entries, each wrapping either a universal handler or a server-config - for (const entry of photon.entries) { - if ( - (entry.env || "ssr") === envName && - // if framework codeSplitting is enabled or if a target has explicitly been set, emit a new entry - (photon.codeSplitting.framework || entry.target) - ) { - this.emitFile({ - type: "chunk", - fileName: ensureExtension(entry.target || entry.name), - id: `${prefix}:${getPhotonServerIdWithEntry(isEdge ? "edge" : "node", entry.name)}`, - }); - } - } - }, - }, - - sharedDuringBuild: true, - }, - { - ...options, - name: `photon:target-loader:${name}:load`, - - resolveId: { - filter: { - id: re_prefix, - }, - - async handler(id, importer, opts) { - const resolved = await this.resolve(id.replace(re_prefix, ""), importer, opts); - - if (!resolved) { - return this.error(`[photon][${name}] Cannot resolve ${id}`); - } - - return { - ...resolved, - // tag module as target entry for other plugins to use - meta: { - ...resolved.meta, - photonConfig: { - ...resolved.meta?.photonConfig, - isTargetEntry: true, - }, - }, - id: `${prefix}:${resolved.id}`, - }; - }, - }, - - load: { - filter: { - id: re_prefix, - }, - - async handler(id, opts) { - const originalEntryId = id.slice(prefix.length + 1); - // At this point, all handlers are wrapped with the server entry, so the entry type is always "server" - const meta = (await getPhotonMeta(this, id)) as Photon.EntryServer; - return options.load.call(this, originalEntryId, { - ...opts, - meta, - }); - }, - }, - - sharedDuringBuild: true, - }, - ] satisfies Plugin[]; -} - -function ensureExtension(id: string) { - if (!id.match(/\.m?js$/)) { - return `${id}.js`; - } - return id; -} diff --git a/packages/core/src/plugin/utils/entry.ts b/packages/core/src/plugin/utils/entry.ts deleted file mode 100644 index 0d67ad38..00000000 --- a/packages/core/src/plugin/utils/entry.ts +++ /dev/null @@ -1,23 +0,0 @@ -import type { Photon } from "../../types.js"; - -// biome-ignore lint/suspicious/noExplicitAny: any -type AnyRecord = Record; - -export function isPhotonMeta(meta?: T): meta is T & { photon: PhotonMeta } { - return Boolean(meta && "photon" in meta); -} - -export function isPhotonMetaConfig(meta?: T): meta is T & { photonConfig: PhotonMetaConfig } { - return Boolean(meta && "photonConfig" in meta); -} - -export type PhotonMeta = Photon.EntryServer | Photon.EntryUniversalHandler; - -export interface PhotonMetaConfig { - /** - * If true, whenever a module with this config triggers `hotUpdate`, - * a 'full-reload' will occur. - */ - isGlobal?: boolean; - isTargetEntry?: boolean; -} diff --git a/packages/core/src/plugin/utils/escapeStringRegexp.ts b/packages/core/src/plugin/utils/escapeStringRegexp.ts deleted file mode 100644 index c3b3fb51..00000000 --- a/packages/core/src/plugin/utils/escapeStringRegexp.ts +++ /dev/null @@ -1,4 +0,0 @@ -// Credit: https://github.com/sindresorhus/escape-string-regexp/blob/main/index.js -export function escapeStringRegexp(subject: string) { - return subject.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d"); -} diff --git a/packages/core/src/plugin/utils/isBun.ts b/packages/core/src/plugin/utils/isBun.ts deleted file mode 100644 index 63ccc1be..00000000 --- a/packages/core/src/plugin/utils/isBun.ts +++ /dev/null @@ -1 +0,0 @@ -export const isBun = typeof Bun !== "undefined"; diff --git a/packages/core/src/plugin/utils/isDeno.ts b/packages/core/src/plugin/utils/isDeno.ts deleted file mode 100644 index 7489cc14..00000000 --- a/packages/core/src/plugin/utils/isDeno.ts +++ /dev/null @@ -1 +0,0 @@ -export const isDeno = typeof Deno !== "undefined"; diff --git a/packages/core/src/plugin/utils/logVite.ts b/packages/core/src/plugin/utils/logVite.ts deleted file mode 100644 index 0fe0cbd6..00000000 --- a/packages/core/src/plugin/utils/logVite.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { bold, cyan } from "ansis"; - -export { logViteInfo }; - -function logViteInfo(message: string) { - console.log(`${bold(cyan("[vite]"))} ${message}`); -} diff --git a/packages/core/src/plugin/utils/servers.ts b/packages/core/src/plugin/utils/servers.ts deleted file mode 100644 index c12d510a..00000000 --- a/packages/core/src/plugin/utils/servers.ts +++ /dev/null @@ -1,19 +0,0 @@ -import type { SupportedServers } from "../../validators/types.js"; - -function getImports(id: string) { - return [id, `@photonjs/${id}`, `@photonjs/core/${id}`]; -} - -export const serversToImports: Record = { - hono: getImports("hono"), - hattip: getImports("hattip"), - elysia: getImports("elysia"), - h3: getImports("h3"), - express: getImports("express"), - fastify: getImports("fastify"), - srvx: getImports("srvx"), -}; - -export const importsToServer = Object.fromEntries( - Object.entries(serversToImports).flatMap(([k, v]) => v.map((x) => [x, k])), -) as Record; diff --git a/packages/core/src/plugin/utils/universal.ts b/packages/core/src/plugin/utils/universal.ts deleted file mode 100644 index 435d7da1..00000000 --- a/packages/core/src/plugin/utils/universal.ts +++ /dev/null @@ -1,20 +0,0 @@ -import { type EnhancedMiddleware, getUniversal, nameSymbol } from "@universal-middleware/core"; -import { PhotonConfigError } from "../../utils/assert.js"; - -type ErrorMessage = (id: string, i: number) => string; - -export function extractUniversal( - mi: EnhancedMiddleware | EnhancedMiddleware[], - id: string, - errorMessage: ErrorMessage, -) { - return [mi] - .flat(Number.POSITIVE_INFINITY) - .map((x) => getUniversal(x as EnhancedMiddleware)) - .map((m, i) => { - if (typeof m === "function" && nameSymbol in m) { - return m; - } - throw new PhotonConfigError(errorMessage(id, i)); - }); -} diff --git a/packages/core/src/plugin/utils/virtual.ts b/packages/core/src/plugin/utils/virtual.ts deleted file mode 100644 index 403afd98..00000000 --- a/packages/core/src/plugin/utils/virtual.ts +++ /dev/null @@ -1,100 +0,0 @@ -export function regexGroups(regex: RegExp) { - return { - regex, - match(x?: string) { - if (x === undefined) return null; - const match = x.match(regex); - if (match === null) return null; - return match.groups as T; - }, - }; -} - -export const virtualModules = { - "virtual-entry": regexGroups<{ uniqueId: string; entry: string }>( - /^virtual:photon:virtual-entry:(?.+?):(?.+)/, - ), - "handler-entry": regexGroups<{ entry: string }>(/^virtual:photon:handler-entry:(?.+)/), - "server-entry": regexGroups<{ entry?: string }>(/^virtual:photon:server-entry(?:$|:(?.+))/), - "server-entry-with-entry": regexGroups<{ condition: string; entry: string }>( - /^virtual:photon:server-entry-with-entry:(?.+?):(?.+)/, - ), - "fallback-entry": regexGroups(/^virtual:photon:fallback-entry/), - "resolve-from-photon": regexGroups<{ module: string }>(/^virtual:photon:resolve-from-photon:(?.+)/), - "get-middlewares": regexGroups<{ condition: string; server: string; handler?: string }>( - /^virtual:photon:get-middlewares:(?.+?):(?[^:]+)(?::(?.+))?/, - ), -}; - -export const virtualModulesRegex = Object.fromEntries( - Object.entries(virtualModules).map(([k, v]) => [k, v.regex]), -) as Record; - -type VirtualModuleKeys = keyof typeof virtualModules; -type ExtractArgs = NonNullable< - ReturnType<(typeof virtualModules)[K extends VirtualModuleKeys ? K : K[number]]["match"]> ->; - -export function ifPhotonModule< - K extends VirtualModuleKeys | VirtualModuleKeys[], - // biome-ignore lint/suspicious/noExplicitAny: any - F extends (arg: ExtractArgs) => any, ->(key: K, value: unknown, callback: F): null | ReturnType; -export function ifPhotonModule< - K extends VirtualModuleKeys | VirtualModuleKeys[], - // biome-ignore lint/suspicious/noExplicitAny: any - F extends (arg: ExtractArgs) => any, - R, ->( - key: K, - value: unknown, - callback: F, - next: R, -): R extends Error - ? ReturnType - : // biome-ignore lint/suspicious/noExplicitAny: any - R extends (...args: any[]) => any - ? ReturnType | ReturnType - : R | ReturnType; -export function ifPhotonModule< - K extends VirtualModuleKeys | VirtualModuleKeys[], - // biome-ignore lint/suspicious/noExplicitAny: any - F extends (arg: ExtractArgs) => any, ->(key: K, value: unknown, callback: F, next: unknown = null): unknown | ReturnType { - function returnOrThrow() { - if (next instanceof Error) { - throw next; - } - if (typeof next === "function") { - return next(); - } - - return next; - } - - if (Array.isArray(key)) { - for (const k of key) { - // biome-ignore lint/suspicious/noExplicitAny: any - const r = ifPhotonModule(k as VirtualModuleKeys, value, callback as any); - if (r !== null) return r; - } - return returnOrThrow(); - } - - // biome-ignore lint/suspicious/noExplicitAny: any - const out = virtualModules[key as VirtualModuleKeys].match(value as any); - - if (out === null) { - return returnOrThrow(); - } - - // biome-ignore lint/suspicious/noExplicitAny: any - return callback(out as any); -} - -export function asPhotonEntryId(id: string, type: "handler-entry" | "server-entry" | "server-config") { - if (id.startsWith(`virtual:photon:${type}`)) { - return id; - } - return `virtual:photon:${type}:${id}`; -} diff --git a/packages/core/src/runtime/adapters/handleViteDevServer.ts b/packages/core/src/runtime/adapters/handleViteDevServer.ts deleted file mode 100644 index 126d863d..00000000 --- a/packages/core/src/runtime/adapters/handleViteDevServer.ts +++ /dev/null @@ -1,20 +0,0 @@ -export { handleViteDevServer }; - -import type { IncomingMessage, ServerResponse } from "node:http"; -import { assert } from "../../utils/assert.js"; -import { globalStore } from "../globalStore.js"; - -/** - * If vite dev middlewares return a response, we need to forward it to our actual server - */ -function handleViteDevServer(req: IncomingMessage, res: ServerResponse): Promise { - return new Promise((resolve) => { - res.once("close", () => { - resolve(true); - }); - assert(globalStore.viteDevServer); - globalStore.viteDevServer.middlewares(req, res, () => { - resolve(false); - }); - }); -} diff --git a/packages/core/src/runtime/globalStore.ts b/packages/core/src/runtime/globalStore.ts deleted file mode 100644 index bfc8b826..00000000 --- a/packages/core/src/runtime/globalStore.ts +++ /dev/null @@ -1,7 +0,0 @@ -import type { ViteDevServer } from "vite"; - -// @ts-expect-error -// biome-ignore lint/suspicious/noAssignInExpressions: allowed -export const globalStore = (globalThis.__vikeNode ||= {}) as { - viteDevServer?: ViteDevServer | false; -}; diff --git a/packages/core/src/utils/assert.ts b/packages/core/src/utils/assert.ts deleted file mode 100644 index 9a76771f..00000000 --- a/packages/core/src/utils/assert.ts +++ /dev/null @@ -1,83 +0,0 @@ -import { red as _red, bold } from "ansis"; - -export { - assert, - assertUsage, - PhotonError, - PhotonBugError, - PhotonUsageError, - PhotonConfigError, - PhotonRuntimeError, - PhotonDependencyError, -}; - -/** - * Base class for all PhotonJS errors - */ -abstract class PhotonError extends Error { - protected constructor(category: string, message: string, options?: ErrorOptions) { - super(`${red(`[photon][${category}]`)} ${message}`, options); - this.name = this.constructor.name; - } -} - -/** - * Internal PhotonJS bugs that should be reported to maintainers - */ -class PhotonBugError extends PhotonError { - constructor(message?: string, options?: ErrorOptions) { - const defaultMessage = - "You stumbled upon a PhotonJS bug. Reach out on GitHub and copy-paste this error — a maintainer will fix the bug."; - super("Bug", `${message || defaultMessage}`, options); - } -} - -/** - * User errors due to incorrect usage - */ -class PhotonUsageError extends PhotonError { - constructor(message: string, options?: ErrorOptions) { - super("Wrong Usage", message, options); - } -} - -/** - * Configuration errors - */ -class PhotonConfigError extends PhotonError { - constructor(message: string, options?: ErrorOptions) { - super("Config Error", message, options); - } -} - -/** - * Runtime errors during execution - */ -class PhotonRuntimeError extends PhotonError { - constructor(message: string, options?: ErrorOptions) { - super("Runtime Error", message, options); - } -} - -/** - * Missing dependency errors - */ -class PhotonDependencyError extends PhotonError { - constructor(message: string, options?: ErrorOptions) { - super("Dependency Error", message, options); - } -} - -function assert(condition: unknown): asserts condition { - if (condition) return; - throw new PhotonBugError(); -} - -function assertUsage(condition: unknown, message: string): asserts condition { - if (condition) return; - throw new PhotonUsageError(message); -} - -function red(str: string) { - return _red(bold(str)); -} diff --git a/packages/core/src/utils/deferred.ts b/packages/core/src/utils/deferred.ts deleted file mode 100644 index 2e13668a..00000000 --- a/packages/core/src/utils/deferred.ts +++ /dev/null @@ -1,17 +0,0 @@ -export interface Deferred { - promise: Promise; - resolve: (value: T | PromiseLike) => void; - reject: (reason?: unknown) => void; -} - -export function createDeferred(): Deferred { - let resolve!: (value: T | PromiseLike) => void; - let reject!: (reason?: unknown) => void; - - const promise = new Promise((res, rej) => { - resolve = res; - reject = rej; - }); - - return { promise, resolve, reject }; -} diff --git a/packages/core/src/utils/meta.ts b/packages/core/src/utils/meta.ts deleted file mode 100644 index 061717c2..00000000 --- a/packages/core/src/utils/meta.ts +++ /dev/null @@ -1,47 +0,0 @@ -import { isPhotonMeta, type PhotonMeta } from "../plugin/utils/entry.js"; -import type { PluginContext } from "../plugin/utils/rollupTypes.js"; -import { asPhotonEntryId } from "../plugin/utils/virtual.js"; -import type { Photon } from "../types.js"; -import { assertUsage, PhotonUsageError } from "./assert.js"; - -interface HintToMeta { - "handler-entry": Photon.EntryUniversalHandler; - "server-entry": Photon.EntryServer; -} - -/** - * Retrieves Photon metadata associated with a specific entry - */ -export async function getPhotonMeta( - pluginContext: PluginContext, - id: string, - hint?: T, -): Promise { - const actualId = hint ? asPhotonEntryId(id, hint) : id; - - { - const info = pluginContext.getModuleInfo(actualId); - if (isPhotonMeta(info?.meta)) { - // biome-ignore lint/suspicious/noExplicitAny: any - return info.meta.photon as any; - } - } - - const resolved = await pluginContext.resolve(actualId); - assertUsage(resolved, `Could not resolve ${actualId}`); - - if (isPhotonMeta(resolved.meta)) { - // biome-ignore lint/suspicious/noExplicitAny: any - return resolved.meta.photon as any; - } - - { - const info = pluginContext.getModuleInfo(resolved.id); - if (isPhotonMeta(info?.meta)) { - // biome-ignore lint/suspicious/noExplicitAny: any - return info.meta.photon as any; - } - } - - throw new PhotonUsageError(`Could not find Photon meta for "${id}" (hint: ${hint})`); -} diff --git a/packages/core/src/validators/coerce.ts b/packages/core/src/validators/coerce.ts deleted file mode 100644 index a5d494a3..00000000 --- a/packages/core/src/validators/coerce.ts +++ /dev/null @@ -1,168 +0,0 @@ -import { asPhotonEntryId } from "../plugin/utils/virtual.js"; -import type { Photon } from "../types.js"; -import { assert, PhotonConfigError } from "../utils/assert.js"; -import type { PhotonConfig, PhotonEntryPartial, PhotonEntryServerPartial } from "./types.js"; -import * as Validators from "./validators.js"; - -export function entryToPhoton( - defaultType: "server-entry", - entry: string | PhotonEntryServerPartial, - name: "index", -): Photon.EntryServer; -export function entryToPhoton( - defaultType: "handler-entry", - entry: string | PhotonEntryPartial, - name: string, -): Photon.EntryUniversalHandler | Photon.EntryServerConfig; -export function entryToPhoton( - defaultType: "server-entry" | "handler-entry", - entry: string | PhotonEntryServerPartial | PhotonEntryPartial, - name: string, -): Photon.Entry { - assert(name); - if (typeof entry === "string") { - return { - id: asPhotonEntryId(entry, defaultType), - name, - type: defaultType === "server-entry" ? "server" : "universal-handler", - }; - } - if (entry.type === "server-config" || entry.id === "virtual:photon:server-entry" || !entry.id) { - return { - ...entry, - id: "virtual:photon:server-entry", - type: "server-config", - name, - }; - } - return { - ...entry, - id: asPhotonEntryId(entry.id, defaultType), - type: defaultType === "server-entry" ? "server" : "universal-handler", - name, - }; -} - -function entriesToPhoton( - entries: PhotonConfig["entries"], -): (Photon.EntryUniversalHandler | Photon.EntryServerConfig)[] { - return Object.entries(entries ?? {}).map(([key, value]) => entryToPhoton("handler-entry", value, key)); -} - -function excludeTrue(v: T): Partial> { - if (v === true) return {}; - return v as Exclude; -} - -const resolver = Validators.PhotonConfig.transform((c) => { - return Validators.PhotonConfigResolved.parse({ - // Allows Photon targets to add custom options - ...c, - entries: entriesToPhoton(c.entries), - server: c.server - ? entryToPhoton("server-entry", c.server, "index") - : entryToPhoton( - "server-entry", - { - id: "virtual:photon:fallback-entry", - type: "server", - server: "srvx", - }, - "index", - ), - devServer: - c.devServer === false - ? false - : { - env: excludeTrue(c.devServer)?.env ?? "ssr", - autoServe: excludeTrue(c.devServer)?.autoServe ?? true, - }, - middlewares: c.middlewares ?? [], - codeSplitting: { - framework: c.codeSplitting?.framework ?? true, - target: c.codeSplitting?.target ?? false, - }, - defaultBuildEnv: c.defaultBuildEnv ?? "ssr", - hmr: c.hmr ?? true, - target: c.target, - emitEntry: c.emitEntry ?? true, - }); -}); - -export function mergePhotonConfig(configs: Photon.Config[]): Photon.Config { - const resolving: Photon.Config = {}; - resolving.entries = {}; - resolving.middlewares = []; - resolving.codeSplitting = {}; - for (const config of configs) { - // server - if (config.server) { - resolving.server = config.server; - } - - // entries - // Check for duplicate entries - if (config.entries) { - const names = new Set(); - for (const name of [...Object.keys(resolving.entries), ...Object.keys(config.entries)]) { - if (names.has(name)) { - throw new PhotonConfigError(`Duplicate entry name: ${name}`); - } - names.add(name); - } - Object.assign(resolving.entries, config.entries); - } - - // middlewares - if (config.middlewares) { - resolving.middlewares.push(...config.middlewares); - } - - // devServer - // if devServer has already been set to false, keep it that way - if (resolving.devServer !== false) { - if (config.devServer === false) { - resolving.devServer = false; - } else if (config.devServer) { - resolving.devServer = config.devServer; - } - } - - // hmr - if (typeof config.hmr !== "undefined") { - resolving.hmr = config.hmr; - } - - // codeSplitting - // if codeSplitting has already been set to false, keep it that way - if (resolving.codeSplitting.framework !== false) { - if (typeof config.codeSplitting?.framework !== "undefined") { - resolving.codeSplitting.framework = config.codeSplitting.framework; - } - } - if (resolving.codeSplitting.target !== false) { - if (typeof config.codeSplitting?.target !== "undefined") { - resolving.codeSplitting.target = config.codeSplitting.target; - } - } - - if (config.defaultBuildEnv) { - resolving.defaultBuildEnv = config.defaultBuildEnv; - } - - if (config.target) { - resolving.target = config.target; - } - - if (typeof config.emitEntry === "boolean") { - resolving.emitEntry = config.emitEntry; - } - } - - return resolving; -} - -export function resolvePhotonConfig(config: Photon.Config | Photon.Config[] | undefined): Photon.ConfigResolved { - const _config: Photon.Config | undefined = Array.isArray(config) ? mergePhotonConfig(config) : config; - return resolver.parse(_config ?? {}); -} diff --git a/packages/core/src/validators/types.ts b/packages/core/src/validators/types.ts deleted file mode 100644 index 8550a4f2..00000000 --- a/packages/core/src/validators/types.ts +++ /dev/null @@ -1,17 +0,0 @@ -import type { z } from "zod"; -import type * as Validators from "./validators.js"; - -export type SupportedServers = z.infer; - -export type PhotonEntryServer = z.infer; -export type PhotonEntryServerPartial = z.infer; -export type PhotonEntryServerConfig = z.infer; -export type PhotonEntryUniversalHandler = z.infer; -export type PhotonEntryBase = z.infer; -export type PhotonEntryPartial = z.infer; - -export type PhotonConfig = z.infer; - -export type PhotonConfigResolved = z.infer; - -export type GetPhotonCondition = Validators.GetPhotonCondition; diff --git a/packages/core/src/validators/validators.ts b/packages/core/src/validators/validators.ts deleted file mode 100644 index 984147a0..00000000 --- a/packages/core/src/validators/validators.ts +++ /dev/null @@ -1,118 +0,0 @@ -import type { ViteDevServer } from "vite"; -import * as z from "zod"; -import type { PluginContext } from "../plugin/utils/rollupTypes.js"; - -// biome-ignore lint/suspicious/noConfusingVoidType: prefer void -type GetPhotonConditionReturn = string | string[] | undefined | null | void; - -// FIXME should server be optional? -export type GetPhotonCondition = ( - this: ViteDevServer | PluginContext, - condition: "dev" | "edge" | "node", - server: string, -) => GetPhotonConditionReturn | Promise; - -export const SupportedServers = z.enum(["hono", "hattip", "elysia", "express", "fastify", "h3", "srvx"]); - -export const PhotonEntryBase = z.object({ - id: z.string(), - name: z.string(), - target: z.string().optional(), - route: z.string().optional(), - resolvedId: z.string().optional(), -}); - -export const PhotonEntryServer = PhotonEntryBase.extend({ - type: z.literal("server"), - server: SupportedServers.optional(), -}).loose(); - -export const PhotonEntryServerPartial = PhotonEntryServer.extend({ - type: PhotonEntryServer.shape.type.optional(), -}) - .omit({ - name: true, - }) - .loose(); - -export const PhotonEntryUniversalHandler = PhotonEntryBase.extend({ - type: z.literal("universal-handler"), - /** - * If undefined or 'auto', all middlewares will be applied to it. - * If 'isolated', no middlewares will be applied. - * @alpha - */ - compositionMode: z.enum(["isolated", "auto"]).optional(), - env: z.string().optional(), -}).loose(); - -export const PhotonEntryServerConfig = PhotonEntryBase.extend({ - id: z.literal("virtual:photon:server-entry"), - type: z.literal("server-config"), - compositionMode: PhotonEntryUniversalHandler.shape.compositionMode, - env: PhotonEntryUniversalHandler.shape.env, -}).loose(); - -export const PhotonEntryPartial = PhotonEntryUniversalHandler.extend({ - type: z.enum(["universal-handler", "server-config"]).optional(), -}).partial(); - -export const PhotonConfig = z.looseObject({ - server: z.union([z.string(), PhotonEntryServerPartial]).optional(), - // This means that only a framework setting codeSplitting: false can also add entries without .id - entries: z.record(z.string(), z.union([z.string(), PhotonEntryPartial])).optional(), - hmr: z.union([z.boolean(), z.literal("prefer-restart")]).optional(), - middlewares: z - .array( - z.custom((fn) => { - return typeof fn === "function"; - }), - ) - .optional(), - defaultBuildEnv: z.string().optional(), - /** - * Can be set to false by frameworks or deployment targets if code splitting is not supported - */ - codeSplitting: z - .object({ - framework: z.boolean().optional(), - target: z.boolean().optional(), - }) - .optional(), - devServer: z - .union([ - z.boolean(), - z.object({ - env: z.string().optional(), - autoServe: z.boolean().optional(), - }), - ]) - .optional(), - target: z.string().optional(), - emitEntry: z.boolean().optional(), -}); - -export const PhotonConfigResolved = z.looseObject({ - server: PhotonEntryServer, - entries: z.array(z.union([PhotonEntryUniversalHandler, PhotonEntryServerConfig])), - hmr: z.union([z.boolean(), z.literal("prefer-restart")]), - middlewares: z.array( - z.custom((fn) => { - return typeof fn === "function"; - }), - ), - defaultBuildEnv: z.string(), - codeSplitting: z.object({ - framework: z.boolean(), - target: z.boolean(), - }), - devServer: z.union([ - z.literal(false), - z.object({ - env: z.string(), - autoServe: z.boolean(), - }), - ]), - target: z.string().optional(), - emitEntry: z.boolean(), -}); From 43b1cca104a5b65d5d6451d25dcc9b1d37f9791f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Wed, 21 Jan 2026 13:32:04 +0100 Subject: [PATCH 02/62] feat: wip migration to UD --- example/app-cloudflare/package.json | 1 - example/app-netlify/package.json | 1 - example/awesome-framework/package.json | 17 +- .../src/photon/entries/api.ts | 10 + .../src/photon/entries/dev.ts | 6 - .../src/photon/entries/edge.ts | 6 - .../src/photon/entries/node.ts | 13 - .../src/photon/entries/ssr.ts | 12 + .../src/photon/entries/standalone.ts | 21 - .../src/photon/entries/virtual.ts | 5 + .../src/photon/middlewares/api.ts | 18 - .../src/photon/middlewares/index.ts | 4 + .../src/photon/middlewares/ssr.ts | 19 - .../src/vite/awesomeFrameworkPlugin.ts | 16 + example/awesome-framework/src/vite/index.ts | 4 +- .../src/vite/photonPlugin.ts | 28 - example/awesome-framework/virtual.d.ts | 6 + packages/hono/src/apply-dev.ts | 7 +- pnpm-lock.yaml | 4186 +---------------- tests/app/hmr-route.ts | 13 +- tests/app/hono-entry.ts | 10 +- tests/app/package.json | 3 +- tests/app/vite.config.ts | 33 +- 23 files changed, 267 insertions(+), 4172 deletions(-) create mode 100644 example/awesome-framework/src/photon/entries/api.ts delete mode 100644 example/awesome-framework/src/photon/entries/dev.ts delete mode 100644 example/awesome-framework/src/photon/entries/edge.ts delete mode 100644 example/awesome-framework/src/photon/entries/node.ts create mode 100644 example/awesome-framework/src/photon/entries/ssr.ts delete mode 100644 example/awesome-framework/src/photon/entries/standalone.ts create mode 100644 example/awesome-framework/src/photon/entries/virtual.ts delete mode 100644 example/awesome-framework/src/photon/middlewares/api.ts create mode 100644 example/awesome-framework/src/photon/middlewares/index.ts delete mode 100644 example/awesome-framework/src/photon/middlewares/ssr.ts delete mode 100644 example/awesome-framework/src/vite/photonPlugin.ts diff --git a/example/app-cloudflare/package.json b/example/app-cloudflare/package.json index d1cddbf2..ecf11322 100644 --- a/example/app-cloudflare/package.json +++ b/example/app-cloudflare/package.json @@ -10,7 +10,6 @@ "test:types": "tsc --noEmit" }, "devDependencies": { - "@photonjs/cloudflare": "^0.1.13", "@photonjs/core": "^0.1.21", "@photonjs/hono": "^0.1.12", "@photonjs/runtime": "^0.1.16", diff --git a/example/app-netlify/package.json b/example/app-netlify/package.json index 03cf42d9..f560a465 100644 --- a/example/app-netlify/package.json +++ b/example/app-netlify/package.json @@ -12,7 +12,6 @@ }, "devDependencies": { "@photonjs/core": "^0.1.21", - "@photonjs/netlify": "workspace:^", "@photonjs/runtime": "^0.1.16", "e2e": "workspace:", "playwright": "^1.57.0", diff --git a/example/awesome-framework/package.json b/example/awesome-framework/package.json index b92b7eb1..08a7c9f2 100644 --- a/example/awesome-framework/package.json +++ b/example/awesome-framework/package.json @@ -14,6 +14,7 @@ }, "devDependencies": { "@types/node": "^22.19.1", + "@universal-deploy/store": "^0.0.2", "typescript": "^5.9.3", "vite": "^7.2.4" }, @@ -22,17 +23,9 @@ "./entry-client": "./dist/entry-client.js", "./render": "./dist/render.js", "./vite": "./dist/vite/index.js", - "./standalone": "./dist/photon/entries/standalone.js", - "./universal-middleware": { - "types": "./dist/photon/entries/edge.d.ts", - "development": "./dist/photon/entries/dev.js", - "workerd": "./dist/photon/entries/edge.js", - "worker": "./dist/photon/entries/edge.js", - "deno": "./dist/photon/entries/node.js", - "bun": "./dist/photon/entries/node.js", - "node": "./dist/photon/entries/node.js", - "import": "./dist/photon/entries/edge.js", - "default": "./dist/photon/entries/edge.js" - } + "./entries/api": "./dist/photon/entries/api.js", + "./entries/ssr": "./dist/photon/entries/ssr.js", + "./server-entry": "./dist/photon/entries/virtual.js", + "./middlewares": "./dist/photon/middlewares/index.js" } } diff --git a/example/awesome-framework/src/photon/entries/api.ts b/example/awesome-framework/src/photon/entries/api.ts new file mode 100644 index 00000000..84556a4e --- /dev/null +++ b/example/awesome-framework/src/photon/entries/api.ts @@ -0,0 +1,10 @@ +export default { + fetch() { + return new Response("The API Route", { + status: 200, + headers: { + "Content-Type": "text/plain", + }, + }); + }, +}; diff --git a/example/awesome-framework/src/photon/entries/dev.ts b/example/awesome-framework/src/photon/entries/dev.ts deleted file mode 100644 index 0538c1c4..00000000 --- a/example/awesome-framework/src/photon/entries/dev.ts +++ /dev/null @@ -1,6 +0,0 @@ -import type { UniversalMiddleware } from "@universal-middleware/core"; -import { apiMiddleware } from "../middlewares/api"; -import { loggerMiddleware } from "../middlewares/logger"; -import { ssrMiddleware } from "../middlewares/ssr"; - -export default [loggerMiddleware, apiMiddleware, ssrMiddleware] as UniversalMiddleware[]; diff --git a/example/awesome-framework/src/photon/entries/edge.ts b/example/awesome-framework/src/photon/entries/edge.ts deleted file mode 100644 index 0538c1c4..00000000 --- a/example/awesome-framework/src/photon/entries/edge.ts +++ /dev/null @@ -1,6 +0,0 @@ -import type { UniversalMiddleware } from "@universal-middleware/core"; -import { apiMiddleware } from "../middlewares/api"; -import { loggerMiddleware } from "../middlewares/logger"; -import { ssrMiddleware } from "../middlewares/ssr"; - -export default [loggerMiddleware, apiMiddleware, ssrMiddleware] as UniversalMiddleware[]; diff --git a/example/awesome-framework/src/photon/entries/node.ts b/example/awesome-framework/src/photon/entries/node.ts deleted file mode 100644 index 231e1255..00000000 --- a/example/awesome-framework/src/photon/entries/node.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { enhance, type UniversalMiddleware } from "@universal-middleware/core"; -import sirv from "@universal-middleware/sirv"; -import { apiMiddleware } from "../middlewares/api"; -import { loggerMiddleware } from "../middlewares/logger"; -import { ssrMiddleware } from "../middlewares/ssr"; - -// Production with Node.js/Bun/Deno -export default [ - loggerMiddleware, - enhance(sirv("dist/client"), { name: "sirv" }), - apiMiddleware, - ssrMiddleware, -] as UniversalMiddleware[]; diff --git a/example/awesome-framework/src/photon/entries/ssr.ts b/example/awesome-framework/src/photon/entries/ssr.ts new file mode 100644 index 00000000..60b1ad6e --- /dev/null +++ b/example/awesome-framework/src/photon/entries/ssr.ts @@ -0,0 +1,12 @@ +import indexHtml from "virtual:awesome-plugin:index-js"; + +export default { + fetch() { + return new Response(indexHtml, { + status: 200, + headers: { + "Content-Type": "text/html", + }, + }); + }, +}; diff --git a/example/awesome-framework/src/photon/entries/standalone.ts b/example/awesome-framework/src/photon/entries/standalone.ts deleted file mode 100644 index d3fa2dfd..00000000 --- a/example/awesome-framework/src/photon/entries/standalone.ts +++ /dev/null @@ -1,21 +0,0 @@ -import { enhance } from "@universal-middleware/core"; - -const standaloneMiddleware = enhance( - async () => { - return new Response("The /standalone Route", { - status: 200, - headers: { - "Content-Type": "text/plain", - }, - }); - }, - // enhance() adds meta data (a Universal Middleware in itself is just a Request => Response function) - { - name: "awesome-framework:standalone", - path: "/standalone", - method: "GET", - }, -); - -// This middleware will be used as a standalone handler, which means it is not included by `./universal-middleware` export -export default standaloneMiddleware; diff --git a/example/awesome-framework/src/photon/entries/virtual.ts b/example/awesome-framework/src/photon/entries/virtual.ts new file mode 100644 index 00000000..1cba5834 --- /dev/null +++ b/example/awesome-framework/src/photon/entries/virtual.ts @@ -0,0 +1,5 @@ +import fetchable from "virtual:ud:catch-all"; + +export * from "virtual:ud:catch-all"; + +export default fetchable; diff --git a/example/awesome-framework/src/photon/middlewares/api.ts b/example/awesome-framework/src/photon/middlewares/api.ts deleted file mode 100644 index ae14b29e..00000000 --- a/example/awesome-framework/src/photon/middlewares/api.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { enhance } from "@universal-middleware/core"; - -export const apiMiddleware = enhance( - async () => { - return new Response("The API Route", { - status: 200, - headers: { - "Content-Type": "text/plain", - }, - }); - }, - // enhance() adds meta data (a Universal Middleware in itself is just a Request => Response function) - { - name: "awesome-framework:api-route", - path: "/api", - method: "GET", - }, -); diff --git a/example/awesome-framework/src/photon/middlewares/index.ts b/example/awesome-framework/src/photon/middlewares/index.ts new file mode 100644 index 00000000..3fe6d196 --- /dev/null +++ b/example/awesome-framework/src/photon/middlewares/index.ts @@ -0,0 +1,4 @@ +import type { UniversalMiddleware } from "@universal-middleware/core"; +import { loggerMiddleware } from "./logger"; + +export default [loggerMiddleware] as UniversalMiddleware[]; diff --git a/example/awesome-framework/src/photon/middlewares/ssr.ts b/example/awesome-framework/src/photon/middlewares/ssr.ts deleted file mode 100644 index 378933ac..00000000 --- a/example/awesome-framework/src/photon/middlewares/ssr.ts +++ /dev/null @@ -1,19 +0,0 @@ -import indexHtml from "virtual:awesome-plugin:index-js"; -import { enhance } from "@universal-middleware/core"; - -export const ssrMiddleware = enhance( - async (_request: Request) => { - return new Response(indexHtml, { - status: 200, - headers: { - "Content-Type": "text/html", - }, - }); - }, - // enhance() adds meta data (a Universal Middleware in itself is just a Request => Response function) - { - name: "awesome-framework:ssr", - path: "/**", - method: "GET", - }, -); diff --git a/example/awesome-framework/src/vite/awesomeFrameworkPlugin.ts b/example/awesome-framework/src/vite/awesomeFrameworkPlugin.ts index c2cb4913..016b8d43 100644 --- a/example/awesome-framework/src/vite/awesomeFrameworkPlugin.ts +++ b/example/awesome-framework/src/vite/awesomeFrameworkPlugin.ts @@ -1,3 +1,4 @@ +import { store } from "@universal-deploy/store"; import type { Plugin } from "vite"; import { renderUrl } from "../renderUrl.js"; @@ -5,11 +6,26 @@ const virtualIndex = "virtual:awesome-plugin:index.html"; const virtualIndexSsr = "virtual:awesome-plugin:index-js"; let clientHtml = ""; +let injected = false; export function awesomeFrameworkPlugin(): Plugin[] { return [ { name: "awesome-framework", config() { + if (!injected) { + injected = true; + store.entries.push({ + id: "awesome-framework/entries/api", + pattern: "/api", + method: "GET", + }); + store.entries.push({ + id: "awesome-framework/entries/ssr", + pattern: "/**", + method: "GET", + }); + } + return { ssr: { noExternal: ["awesome-framework"], diff --git a/example/awesome-framework/src/vite/index.ts b/example/awesome-framework/src/vite/index.ts index a6a7041c..ebb25f1a 100644 --- a/example/awesome-framework/src/vite/index.ts +++ b/example/awesome-framework/src/vite/index.ts @@ -1,7 +1,7 @@ +import { catchAll, devServer } from "@universal-deploy/store/vite"; import type { Plugin } from "vite"; import { awesomeFrameworkPlugin } from "./awesomeFrameworkPlugin.js"; -import { photonPlugin } from "./photonPlugin.js"; export function awesomeFramework(): Plugin[] { - return [...awesomeFrameworkPlugin(), ...photonPlugin()]; + return [...awesomeFrameworkPlugin(), catchAll(), devServer()]; } diff --git a/example/awesome-framework/src/vite/photonPlugin.ts b/example/awesome-framework/src/vite/photonPlugin.ts deleted file mode 100644 index cd43eece..00000000 --- a/example/awesome-framework/src/vite/photonPlugin.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { installPhoton } from "@photonjs/runtime/vite"; -import type { Plugin } from "vite"; - -export function photonPlugin(): Plugin[] { - return installPhoton("awesome-framework", { - // Disables code-splitting functionality for testing purposes - codeSplitting: { - framework: false, - }, - - // Always use those middlewares for all entries defined by Photon - async resolveMiddlewares() { - return "awesome-framework/universal-middleware"; - }, - - // Configuration for entry points used by Photon - entries: { - standalone: { - // Unique identifier for this entry point. Is resolved by Vite - id: "awesome-framework/standalone", - - // Sets composition mode to 'isolated', preventing it from - // being composed with middlewares defined in `resolveMiddlewares` - compositionMode: "isolated", - }, - }, - }); -} diff --git a/example/awesome-framework/virtual.d.ts b/example/awesome-framework/virtual.d.ts index e88a9e28..04e8756d 100644 --- a/example/awesome-framework/virtual.d.ts +++ b/example/awesome-framework/virtual.d.ts @@ -3,3 +3,9 @@ declare module "virtual:awesome-plugin:*" { const handler: any; export default handler; } + +declare module "virtual:ud:catch-all" { + export default { + fetch(request: Request): Response | Promise {}, + }; +} diff --git a/packages/hono/src/apply-dev.ts b/packages/hono/src/apply-dev.ts index 0e6d07d5..c6e3dbd1 100644 --- a/packages/hono/src/apply-dev.ts +++ b/packages/hono/src/apply-dev.ts @@ -1,7 +1,8 @@ import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:dev:hono"; +import type { Fetchable } from "@photonjs/core/api/internal"; import { createApply } from "@photonjs/core/apply"; import { devServerMiddleware } from "@photonjs/core/dev"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; +import type { RuntimeAdapterTarget, UniversalMiddleware } from "@universal-middleware/core"; import { apply as applyAdapter } from "@universal-middleware/hono"; export const apply = createApply( @@ -12,4 +13,8 @@ export const apply = createApply( devServerMiddleware, ); +function fetchableToUniversalMiddleware(entry: Fetchable): UniversalMiddleware { + return entry.fetch; +} + export type RuntimeAdapter = RuntimeAdapterTarget<"hono">; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index a115a757..e622bfd5 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -72,9 +72,6 @@ importers: specifier: ^4.11.1 version: 4.11.1 devDependencies: - '@photonjs/cloudflare': - specifier: ^0.1.13 - version: link:../../packages/adapter-cloudflare '@photonjs/core': specifier: ^0.1.21 version: link:../../packages/core @@ -146,9 +143,6 @@ importers: '@photonjs/core': specifier: ^0.1.21 version: link:../../packages/core - '@photonjs/netlify': - specifier: workspace:^ - version: link:../../packages/adapter-netlify '@photonjs/runtime': specifier: ^0.1.16 version: link:../../packages/runtime @@ -182,7 +176,7 @@ importers: version: link:../../packages/runtime '@photonjs/vercel': specifier: ^0.1.22 - version: link:../../packages/adapter-vercel + version: 0.1.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(rollup@4.53.5)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) e2e: specifier: 'workspace:' version: link:../../tests/e2e @@ -217,6 +211,9 @@ importers: '@types/node': specifier: ^22.19.1 version: 22.19.1 + '@universal-deploy/store': + specifier: ^0.0.2 + version: 0.0.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) typescript: specifier: ^5.9.3 version: 5.9.3 @@ -228,7 +225,7 @@ importers: dependencies: '@photonjs/cloudflare': specifier: ^0.1.13 - version: link:../../packages/adapter-cloudflare + version: 0.1.13(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0)) '@photonjs/runtime': specifier: ^0.1.16 version: link:../../packages/runtime @@ -306,126 +303,6 @@ importers: specifier: ^5.1.0 version: 5.1.0 - packages/adapter-cloudflare: - dependencies: - '@cloudflare/vite-plugin': - specifier: ^1.19.0 - version: 1.19.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0)) - '@photonjs/core': - specifier: workspace:^ - version: link:../core - '@universal-middleware/cloudflare': - specifier: ^0.4.10 - version: 0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - devDependencies: - '@cloudflare/workers-types': - specifier: ^4.20251219.0 - version: 4.20251219.0 - tsdown: - specifier: ^0.18.1 - version: 0.18.1(typescript@5.9.3) - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - - packages/adapter-netlify: - dependencies: - '@netlify/vite-plugin': - specifier: ^2.7.17 - version: 2.7.17(@netlify/api@14.0.12)(rollup@4.53.5)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) - '@photonjs/core': - specifier: workspace:^ - version: link:../core - devDependencies: - tsdown: - specifier: ^0.18.1 - version: 0.18.1(typescript@5.9.3) - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - - packages/adapter-vercel: - dependencies: - '@brillout/libassert': - specifier: ^0.5.8 - version: 0.5.8 - '@manypkg/find-root': - specifier: ^3.1.0 - version: 3.1.0 - '@photonjs/core': - specifier: workspace:^ - version: link:../core - '@photonjs/runtime': - specifier: workspace:^ - version: link:../runtime - '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/vercel': - specifier: ^0.4.29 - version: 0.4.29(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@vercel/build-utils': - specifier: ^13.2.4 - version: 13.2.4 - '@vercel/nft': - specifier: ^1.1.1 - version: 1.1.1(rollup@4.53.5) - '@vercel/routing-utils': - specifier: ^5.3.1 - version: 5.3.1 - '@vite-plugin-vercel/schemas': - specifier: latest - version: 1.0.0 - convert-route: - specifier: ^0.1.2 - version: 0.1.2 - esbuild: - specifier: ^0.27.2 - version: 0.27.2 - fast-glob: - specifier: ^3.3.3 - version: 3.3.3 - magicast: - specifier: ^0.5.1 - version: 0.5.1 - path-to-regexp: - specifier: ^8.3.0 - version: 8.3.0 - strip-ansi: - specifier: ^7.1.2 - version: 7.1.2 - vite-plugin-wasm: - specifier: ^3.5.0 - version: 3.5.0(vite@7.2.4(@types/node@20.19.25)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) - devDependencies: - '@types/node': - specifier: ^20.19.25 - version: 20.19.25 - '@universal-middleware/express': - specifier: ^0.4.22 - version: 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@vercel/node': - specifier: ^5.5.16 - version: 5.5.16(@swc/core@1.13.5)(rollup@4.53.5) - rollup: - specifier: ^4.53.5 - version: 4.53.5 - tsdown: - specifier: ^0.18.1 - version: 0.18.1(typescript@5.9.3) - typescript: - specifier: ^5.9.3 - version: 5.9.3 - vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@20.19.25)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - packages/core: dependencies: '@brillout/vite-plugin-server-entry': @@ -777,9 +654,6 @@ importers: specifier: ^0.9.8 version: 0.9.8 devDependencies: - '@photonjs/cloudflare': - specifier: workspace:0.1.13 - version: link:../../packages/adapter-cloudflare '@photonjs/core': specifier: workspace:0.1.21 version: link:../../packages/core @@ -807,15 +681,15 @@ importers: '@photonjs/srvx': specifier: workspace:0.1.12 version: link:../../packages/srvx - '@photonjs/vercel': - specifier: workspace:0.1.22 - version: link:../../packages/adapter-vercel '@types/express': specifier: ^5.0.6 version: 5.0.6 '@types/node': specifier: ^22.19.1 version: 22.19.1 + '@universal-deploy/store': + specifier: ^0.0.2 + version: 0.0.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/core': specifier: ^0.4.14 version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -1290,10 +1164,6 @@ packages: '@cloudflare/workers-types@4.20251219.0': resolution: {integrity: sha512-qwuvc3ZDdCfcK9dJrBSFHOsX8kL72sypfBilzEWbbb+slB2NiggjsHeGMV2ZQiQc1zyBMQPjIvsVeE7Apxp7hw==} - '@colors/colors@1.6.0': - resolution: {integrity: sha512-Ir+AOibqzrIsL6ajt3Rz3LskB7OiMVHqltZmspbW/TJuTVuyOMirVqAkjfY6JISiLHgyNqicAC8AyHHGzNd/dA==} - engines: {node: '>=0.1.90'} - '@cspotcode/source-map-support@0.8.1': resolution: {integrity: sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==} engines: {node: '>=12'} @@ -1330,13 +1200,6 @@ packages: resolution: {integrity: sha512-Vd/9EVDiu6PPJt9yAh6roZP6El1xHrdvIVGjyBsHR0RYwNHgL7FJPyIIW4fANJNG6FtyZfvlRPpFI4ZM/lubvw==} engines: {node: '>=18'} - '@dabh/diagnostics@2.0.8': - resolution: {integrity: sha512-R4MSXTVnuMzGD7bzHdW2ZhhdPC/igELENcq5IjEverBvq5hn1SXCWcsi6eSsdWP0/Ur+SItRRjAktmdoX/8R/Q==} - - '@dependents/detective-less@5.0.1': - resolution: {integrity: sha512-Y6+WUMsTFWE5jb20IFP4YGa5IrGY/+a/FbOSjDF/wz9gepU2hwCYSXRHP/vPwBvwcY3SVMASt4yXxbXNXigmZQ==} - engines: {node: '>=18'} - '@docsearch/css@3.9.0': resolution: {integrity: sha512-cQbnVbq0rrBwNAKegIac/t6a8nWoUAn8frnkLFW6YARaRmAQr5/Eoe6Ln2fqkUCZ40KpdrKbpSAmgrkviOxuWA==} @@ -1357,18 +1220,6 @@ packages: search-insights: optional: true - '@edge-runtime/format@2.2.1': - resolution: {integrity: sha512-JQTRVuiusQLNNLe2W9tnzBlV/GvSVcozLl4XZHk5swnRZ/v6jp8TqR8P7sqmJsQqblDZ3EztcWmLDbhRje/+8g==} - engines: {node: '>=16'} - - '@edge-runtime/node-utils@2.3.0': - resolution: {integrity: sha512-uUtx8BFoO1hNxtHjp3eqVPC/mWImGb2exOfGjMLUoipuWgjej+f4o/VP4bUI8U40gu7Teogd5VTeZUkGvJSPOQ==} - engines: {node: '>=16'} - - '@edge-runtime/ponyfill@2.4.2': - resolution: {integrity: sha512-oN17GjFr69chu6sDLvXxdhg0Qe8EZviGSuqzR9qOiKh4MhFYGdBBcqRNzdmYeAdeRzOW2mM9yil4RftUQ7sUOA==} - engines: {node: '>=16'} - '@edge-runtime/primitives@4.1.0': resolution: {integrity: sha512-Vw0lbJ2lvRUqc7/soqygUX216Xb8T3WBZ987oywz6aJqRxcwSVWwr9e+Nqo2m9bxobA9mdbWNNoRY6S9eko1EQ==} engines: {node: '>=16'} @@ -1391,10 +1242,6 @@ packages: '@emnapi/wasi-threads@1.1.0': resolution: {integrity: sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==} - '@envelop/instrumentation@1.0.0': - resolution: {integrity: sha512-cxgkB66RQB95H3X27jlnxCRNTmPuSTgmBAq6/4n2Dtv4hsk4yz8FadA1ggmd0uZzvKqWD6CR+WFgTjhDqg7eyw==} - engines: {node: '>=18.0.0'} - '@esbuild/aix-ppc64@0.23.1': resolution: {integrity: sha512-6VhYk1diRqrhBAqpJEdjASR/+WVRtfjpqKuNw11cLiaWpAT/Uu+nokB+UJnevzy/P9C/ty6AOe0dwueMrGh/iQ==} engines: {node: '>=18'} @@ -2007,19 +1854,9 @@ packages: cpu: [x64] os: [win32] - '@fastify/accept-negotiator@2.0.1': - resolution: {integrity: sha512-/c/TW2bO/v9JeEgoD/g1G5GxGeCF1Hafdf79WPmUlgYiBXummY0oX3VVq4yFkKKVBKDNlaDUYoab7g38RpPqCQ==} - '@fastify/ajv-compiler@4.0.3': resolution: {integrity: sha512-BlVD6YGUTDEl0b5B8TDrvl7JkFNc6LOSybeMB+/bIDA0xaJlBUTeBaGLgjvaviLRNAcBMIXDCHaxOJ8LdlzEKw==} - '@fastify/busboy@2.1.1': - resolution: {integrity: sha512-vBZP4NlzfOlerQTnba4aqZoMhE/a9HY7HRqoOPaETQcSQuWEIyZMHGfVu6w9wGtGK5fED5qRs2DteVCjOH60sA==} - engines: {node: '>=14'} - - '@fastify/busboy@3.2.0': - resolution: {integrity: sha512-m9FVDXU3GT2ITSe0UaMA5rU3QkfC/UXtCU8y0gSN/GugTqtVldOBWIB5V6V3sbmenVZUIpU6f+mPEO2+m5iTaA==} - '@fastify/error@4.2.0': resolution: {integrity: sha512-RSo3sVDXfHskiBZKBPRgnQTtIqpi/7zhJOEmAxCiBcM7d0uwdGdxLlsCaLzGs8v8NnxIRlfG0N51p5yFaOentQ==} @@ -2050,258 +1887,111 @@ packages: peerDependencies: hono: ^4 - '@humanwhocodes/momoa@2.0.4': - resolution: {integrity: sha512-RE815I4arJFtt+FVeU1Tgp9/Xvecacji8w/V6XtXsWWH/wz/eNkNbhb+ny/+PlVZjV0rxQpRSQKNKE3lcktHEA==} - engines: {node: '>=10.10.0'} - - '@iarna/toml@2.2.5': - resolution: {integrity: sha512-trnsAYxU3xnS1gPHPyU961coFyLkh4gAD/0zQ5mymY4yOZ+CYvsPqUbOFSw0aDM4y0tV7tiFxL/1XfXPNC6IPg==} - - '@img/colour@1.0.0': - resolution: {integrity: sha512-A5P/LfWGFSl6nsckYtjw9da+19jB8hkJ6ACTGcDfEJ0aE+l2n2El7dsVM7UVHZQ9s2lmYMWlrS21YLy2IR1LUw==} - engines: {node: '>=18'} - '@img/sharp-darwin-arm64@0.33.5': resolution: {integrity: sha512-UT4p+iz/2H4twwAoLCqfA9UH5pI6DggwKEGuaPy7nCVQ8ZsiY5PIcrRvD1DzuY3qYL07NtIQcWnBSY/heikIFQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [darwin] - '@img/sharp-darwin-arm64@0.34.5': - resolution: {integrity: sha512-imtQ3WMJXbMY4fxb/Ndp6HBTNVtWCUI0WdobyheGf5+ad6xX8VIDO8u2xE4qc/fr08CKG/7dDseFtn6M6g/r3w==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [arm64] - os: [darwin] - '@img/sharp-darwin-x64@0.33.5': resolution: {integrity: sha512-fyHac4jIc1ANYGRDxtiqelIbdWkIuQaI84Mv45KvGRRxSAa7o7d1ZKAOBaYbnepLC1WqxfpimdeWfvqqSGwR2Q==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [darwin] - '@img/sharp-darwin-x64@0.34.5': - resolution: {integrity: sha512-YNEFAF/4KQ/PeW0N+r+aVVsoIY0/qxxikF2SWdp+NRkmMB7y9LBZAVqQ4yhGCm/H3H270OSykqmQMKLBhBJDEw==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [x64] - os: [darwin] - '@img/sharp-libvips-darwin-arm64@1.0.4': resolution: {integrity: sha512-XblONe153h0O2zuFfTAbQYAX2JhYmDHeWikp1LM9Hul9gVPjFY427k6dFEcOL72O01QxQsWi761svJ/ev9xEDg==} cpu: [arm64] os: [darwin] - '@img/sharp-libvips-darwin-arm64@1.2.4': - resolution: {integrity: sha512-zqjjo7RatFfFoP0MkQ51jfuFZBnVE2pRiaydKJ1G/rHZvnsrHAOcQALIi9sA5co5xenQdTugCvtb1cuf78Vf4g==} - cpu: [arm64] - os: [darwin] - '@img/sharp-libvips-darwin-x64@1.0.4': resolution: {integrity: sha512-xnGR8YuZYfJGmWPvmlunFaWJsb9T/AO2ykoP3Fz/0X5XV2aoYBPkX6xqCQvUTKKiLddarLaxpzNe+b1hjeWHAQ==} cpu: [x64] os: [darwin] - '@img/sharp-libvips-darwin-x64@1.2.4': - resolution: {integrity: sha512-1IOd5xfVhlGwX+zXv2N93k0yMONvUlANylbJw1eTah8K/Jtpi15KC+WSiaX/nBmbm2HxRM1gZ0nSdjSsrZbGKg==} - cpu: [x64] - os: [darwin] - '@img/sharp-libvips-linux-arm64@1.0.4': resolution: {integrity: sha512-9B+taZ8DlyyqzZQnoeIvDVR/2F4EbMepXMc/NdVbkzsJbzkUjhXv/70GQJ7tdLA4YJgNP25zukcxpX2/SueNrA==} cpu: [arm64] os: [linux] - '@img/sharp-libvips-linux-arm64@1.2.4': - resolution: {integrity: sha512-excjX8DfsIcJ10x1Kzr4RcWe1edC9PquDRRPx3YVCvQv+U5p7Yin2s32ftzikXojb1PIFc/9Mt28/y+iRklkrw==} - cpu: [arm64] - os: [linux] - '@img/sharp-libvips-linux-arm@1.0.5': resolution: {integrity: sha512-gvcC4ACAOPRNATg/ov8/MnbxFDJqf/pDePbBnuBDcjsI8PssmjoKMAz4LtLaVi+OnSb5FK/yIOamqDwGmXW32g==} cpu: [arm] os: [linux] - '@img/sharp-libvips-linux-arm@1.2.4': - resolution: {integrity: sha512-bFI7xcKFELdiNCVov8e44Ia4u2byA+l3XtsAj+Q8tfCwO6BQ8iDojYdvoPMqsKDkuoOo+X6HZA0s0q11ANMQ8A==} - cpu: [arm] - os: [linux] - - '@img/sharp-libvips-linux-ppc64@1.2.4': - resolution: {integrity: sha512-FMuvGijLDYG6lW+b/UvyilUWu5Ayu+3r2d1S8notiGCIyYU/76eig1UfMmkZ7vwgOrzKzlQbFSuQfgm7GYUPpA==} - cpu: [ppc64] - os: [linux] - - '@img/sharp-libvips-linux-riscv64@1.2.4': - resolution: {integrity: sha512-oVDbcR4zUC0ce82teubSm+x6ETixtKZBh/qbREIOcI3cULzDyb18Sr/Wcyx7NRQeQzOiHTNbZFF1UwPS2scyGA==} - cpu: [riscv64] - os: [linux] - '@img/sharp-libvips-linux-s390x@1.0.4': resolution: {integrity: sha512-u7Wz6ntiSSgGSGcjZ55im6uvTrOxSIS8/dgoVMoiGE9I6JAfU50yH5BoDlYA1tcuGS7g/QNtetJnxA6QEsCVTA==} cpu: [s390x] os: [linux] - '@img/sharp-libvips-linux-s390x@1.2.4': - resolution: {integrity: sha512-qmp9VrzgPgMoGZyPvrQHqk02uyjA0/QrTO26Tqk6l4ZV0MPWIW6LTkqOIov+J1yEu7MbFQaDpwdwJKhbJvuRxQ==} - cpu: [s390x] - os: [linux] - '@img/sharp-libvips-linux-x64@1.0.4': resolution: {integrity: sha512-MmWmQ3iPFZr0Iev+BAgVMb3ZyC4KeFc3jFxnNbEPas60e1cIfevbtuyf9nDGIzOaW9PdnDciJm+wFFaTlj5xYw==} cpu: [x64] os: [linux] - '@img/sharp-libvips-linux-x64@1.2.4': - resolution: {integrity: sha512-tJxiiLsmHc9Ax1bz3oaOYBURTXGIRDODBqhveVHonrHJ9/+k89qbLl0bcJns+e4t4rvaNBxaEZsFtSfAdquPrw==} - cpu: [x64] - os: [linux] - '@img/sharp-libvips-linuxmusl-arm64@1.0.4': resolution: {integrity: sha512-9Ti+BbTYDcsbp4wfYib8Ctm1ilkugkA/uscUn6UXK1ldpC1JjiXbLfFZtRlBhjPZ5o1NCLiDbg8fhUPKStHoTA==} cpu: [arm64] os: [linux] - '@img/sharp-libvips-linuxmusl-arm64@1.2.4': - resolution: {integrity: sha512-FVQHuwx1IIuNow9QAbYUzJ+En8KcVm9Lk5+uGUQJHaZmMECZmOlix9HnH7n1TRkXMS0pGxIJokIVB9SuqZGGXw==} - cpu: [arm64] - os: [linux] - '@img/sharp-libvips-linuxmusl-x64@1.0.4': resolution: {integrity: sha512-viYN1KX9m+/hGkJtvYYp+CCLgnJXwiQB39damAO7WMdKWlIhmYTfHjwSbQeUK/20vY154mwezd9HflVFM1wVSw==} cpu: [x64] os: [linux] - '@img/sharp-libvips-linuxmusl-x64@1.2.4': - resolution: {integrity: sha512-+LpyBk7L44ZIXwz/VYfglaX/okxezESc6UxDSoyo2Ks6Jxc4Y7sGjpgU9s4PMgqgjj1gZCylTieNamqA1MF7Dg==} - cpu: [x64] - os: [linux] - '@img/sharp-linux-arm64@0.33.5': resolution: {integrity: sha512-JMVv+AMRyGOHtO1RFBiJy/MBsgz0x4AWrT6QoEVVTyh1E39TrCUpTRI7mx9VksGX4awWASxqCYLCV4wBZHAYxA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [linux] - '@img/sharp-linux-arm64@0.34.5': - resolution: {integrity: sha512-bKQzaJRY/bkPOXyKx5EVup7qkaojECG6NLYswgktOZjaXecSAeCWiZwwiFf3/Y+O1HrauiE3FVsGxFg8c24rZg==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [arm64] - os: [linux] - '@img/sharp-linux-arm@0.33.5': resolution: {integrity: sha512-JTS1eldqZbJxjvKaAkxhZmBqPRGmxgu+qFKSInv8moZ2AmT5Yib3EQ1c6gp493HvrvV8QgdOXdyaIBrhvFhBMQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm] os: [linux] - '@img/sharp-linux-arm@0.34.5': - resolution: {integrity: sha512-9dLqsvwtg1uuXBGZKsxem9595+ujv0sJ6Vi8wcTANSFpwV/GONat5eCkzQo/1O6zRIkh0m/8+5BjrRr7jDUSZw==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [arm] - os: [linux] - - '@img/sharp-linux-ppc64@0.34.5': - resolution: {integrity: sha512-7zznwNaqW6YtsfrGGDA6BRkISKAAE1Jo0QdpNYXNMHu2+0dTrPflTLNkpc8l7MUP5M16ZJcUvysVWWrMefZquA==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [ppc64] - os: [linux] - - '@img/sharp-linux-riscv64@0.34.5': - resolution: {integrity: sha512-51gJuLPTKa7piYPaVs8GmByo7/U7/7TZOq+cnXJIHZKavIRHAP77e3N2HEl3dgiqdD/w0yUfiJnII77PuDDFdw==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [riscv64] - os: [linux] - '@img/sharp-linux-s390x@0.33.5': resolution: {integrity: sha512-y/5PCd+mP4CA/sPDKl2961b+C9d+vPAveS33s6Z3zfASk2j5upL6fXVPZi7ztePZ5CuH+1kW8JtvxgbuXHRa4Q==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [s390x] os: [linux] - '@img/sharp-linux-s390x@0.34.5': - resolution: {integrity: sha512-nQtCk0PdKfho3eC5MrbQoigJ2gd1CgddUMkabUj+rBevs8tZ2cULOx46E7oyX+04WGfABgIwmMC0VqieTiR4jg==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [s390x] - os: [linux] - '@img/sharp-linux-x64@0.33.5': resolution: {integrity: sha512-opC+Ok5pRNAzuvq1AG0ar+1owsu842/Ab+4qvU879ippJBHvyY5n2mxF1izXqkPYlGuP/M556uh53jRLJmzTWA==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [linux] - '@img/sharp-linux-x64@0.34.5': - resolution: {integrity: sha512-MEzd8HPKxVxVenwAa+JRPwEC7QFjoPWuS5NZnBt6B3pu7EG2Ge0id1oLHZpPJdn3OQK+BQDiw9zStiHBTJQQQQ==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [x64] - os: [linux] - '@img/sharp-linuxmusl-arm64@0.33.5': resolution: {integrity: sha512-XrHMZwGQGvJg2V/oRSUfSAfjfPxO+4DkiRh6p2AFjLQztWUuY/o8Mq0eMQVIY7HJ1CDQUJlxGGZRw1a5bqmd1g==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [arm64] os: [linux] - '@img/sharp-linuxmusl-arm64@0.34.5': - resolution: {integrity: sha512-fprJR6GtRsMt6Kyfq44IsChVZeGN97gTD331weR1ex1c1rypDEABN6Tm2xa1wE6lYb5DdEnk03NZPqA7Id21yg==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [arm64] - os: [linux] - '@img/sharp-linuxmusl-x64@0.33.5': resolution: {integrity: sha512-WT+d/cgqKkkKySYmqoZ8y3pxx7lx9vVejxW/W4DOFMYVSkErR+w7mf2u8m/y4+xHe7yY9DAXQMWQhpnMuFfScw==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [linux] - '@img/sharp-linuxmusl-x64@0.34.5': - resolution: {integrity: sha512-Jg8wNT1MUzIvhBFxViqrEhWDGzqymo3sV7z7ZsaWbZNDLXRJZoRGrjulp60YYtV4wfY8VIKcWidjojlLcWrd8Q==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [x64] - os: [linux] - '@img/sharp-wasm32@0.33.5': resolution: {integrity: sha512-ykUW4LVGaMcU9lu9thv85CbRMAwfeadCJHRsg2GmeRa/cJxsVY9Rbd57JcMxBkKHag5U/x7TSBpScF4U8ElVzg==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [wasm32] - '@img/sharp-wasm32@0.34.5': - resolution: {integrity: sha512-OdWTEiVkY2PHwqkbBI8frFxQQFekHaSSkUIJkwzclWZe64O1X4UlUjqqqLaPbUpMOQk6FBu/HtlGXNblIs0huw==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [wasm32] - - '@img/sharp-win32-arm64@0.34.5': - resolution: {integrity: sha512-WQ3AgWCWYSb2yt+IG8mnC6Jdk9Whs7O0gxphblsLvdhSpSTtmu69ZG1Gkb6NuvxsNACwiPV6cNSZNzt0KPsw7g==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [arm64] - os: [win32] - '@img/sharp-win32-ia32@0.33.5': resolution: {integrity: sha512-T36PblLaTwuVJ/zw/LaH0PdZkRz5rd3SmMHX8GSmR7vtNSP5Z6bQkExdSK7xGWyxLw4sUknBuugTelgw2faBbQ==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [ia32] os: [win32] - '@img/sharp-win32-ia32@0.34.5': - resolution: {integrity: sha512-FV9m/7NmeCmSHDD5j4+4pNI8Cp3aW+JvLoXcTUo0IqyjSfAZJ8dIUmijx1qaJsIiU+Hosw6xM5KijAWRJCSgNg==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [ia32] - os: [win32] - '@img/sharp-win32-x64@0.33.5': resolution: {integrity: sha512-MpY/o8/8kj+EcnxwvrP4aTJSWw/aZ7JIGR4aBeZkZw5B7/Jn+tY9/VNwtcoGmdT7GfggGIU4kygOMSbYnOrAbg==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} cpu: [x64] os: [win32] - '@img/sharp-win32-x64@0.34.5': - resolution: {integrity: sha512-+29YMsqY2/9eFEiW93eqWnuLcWcufowXewwSNIT6UwZdUUCrM3oFjMWH/Z6/TMmb4hlFenmfAVbpWeup2jryCw==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - cpu: [x64] - os: [win32] - - '@import-maps/resolve@2.0.0': - resolution: {integrity: sha512-RwzRTpmrrS6Q1ZhQExwuxJGK1Wqhv4stt+OF2JzS+uawewpwNyU7EJL1WpBex7aDiiGLs4FsXGkfUBdYuX7xiQ==} - '@inquirer/external-editor@1.0.2': resolution: {integrity: sha512-yy9cOoBnx58TlsPrIxauKIFQTiyH+0MK4e97y4sV9ERbI+zDxw7i2hxHLCIEGIE/8PPvDxGhgzIOTSOWcs6/MQ==} engines: {node: '>=18'} @@ -2382,122 +2072,6 @@ packages: '@napi-rs/wasm-runtime@1.1.0': resolution: {integrity: sha512-Fq6DJW+Bb5jaWE69/qOE0D1TUN9+6uWhCeZpdnSBk14pjLcCWR7Q8n49PTSPHazM37JqrsdpEthXy2xn6jWWiA==} - '@netlify/ai@0.3.5': - resolution: {integrity: sha512-7suwHOBy9s14yeWRxt+w3Zh6Rrx8gX7zP/xmsxqxLyJlcBykWm6siBJs2mMtJgbWvcrgI5BEgNLh5qfXlTCsRQ==} - engines: {node: '>=20.6.1'} - peerDependencies: - '@netlify/api': '>=14.0.12' - - '@netlify/api@14.0.12': - resolution: {integrity: sha512-4xSfHAj9PIZZ78YOPby6TBHxYnf6sOE1/jpkHSDyt2oRxF94qJ0fhp96Fo2kq/rIhvgTlU5Ce3HARi8BDY4mLw==} - engines: {node: '>=18.14.0'} - - '@netlify/binary-info@1.0.0': - resolution: {integrity: sha512-4wMPu9iN3/HL97QblBsBay3E1etIciR84izI3U+4iALY+JHCrI+a2jO0qbAZ/nxKoegypYEaiiqWXylm+/zfrw==} - - '@netlify/blobs@10.4.4': - resolution: {integrity: sha512-vN/qi/oqza0l3/nrP5jWcylLPaLBwhhXY5nLckMLyfkSrkUIYvYoAj++l9EF3ZPsptCGeFx9upsW16uQQ85N9w==} - engines: {node: ^14.16.0 || >=16.0.0} - - '@netlify/cache@3.3.4': - resolution: {integrity: sha512-Fl4/KxP8NS7+skjfRixgekuqBNvLPay/J6qC2mxvHjkkZNu1oUs8QOc+T3Nvt4n+UMrltnt9ggg0q/q4hmBIVw==} - engines: {node: '>=20.6.1'} - - '@netlify/config@24.2.0': - resolution: {integrity: sha512-idc1D6kdQOFjG70aZC06crqElTyaSulVlnOEDZX2+5/vcmfFCBu8CJSEd5YzC6VCCXBgOW3Hw0cVxDTl5X6+CQ==} - engines: {node: '>=18.14.0'} - hasBin: true - - '@netlify/dev-utils@4.3.3': - resolution: {integrity: sha512-qziF8R9kf7mRNgSpmUH96O0aV1ZiwK4c9ZecFQbDSQuYhgy9GY1WTjiQF0oQnohjTjWNtXhrU39LAeXWNLaBJg==} - engines: {node: ^18.14.0 || >=20} - - '@netlify/dev@4.8.5': - resolution: {integrity: sha512-Ij/DT9RxV0HbM8x6VMvZ9Ps7kSwvhX/Mgx47BZ5v2dsebnpankNPyMmOUUHw2y16bGOsZQU/nQ8kkhaozSBlYw==} - engines: {node: '>=20.6.1'} - - '@netlify/edge-bundler@14.9.2': - resolution: {integrity: sha512-qJErMNAW48QnvtAJe0yRtz2urenxHUdFhdVpbWoXWuG4Xlq8D06unjl9OfGnymNsoiwLpLcCjEngSNcdZoTa0w==} - engines: {node: '>=18.14.0'} - - '@netlify/edge-functions-bootstrap@2.16.0': - resolution: {integrity: sha512-v8QQihSbBHj3JxtJsHoepXALpNumD9M7egHoc8z62FYl5it34dWczkaJoFFopEyhiBVKi4K/n0ZYpdzwfujd6g==} - - '@netlify/edge-functions-dev@1.0.7': - resolution: {integrity: sha512-PlkG3PxULQ7z/CSzx5LthGsVtJPOo8E+sA67cOwNq/eHxtwpCUfCPOmxq3AGKqMR1pzUGC6k5yewhgXoG8Zm7w==} - engines: {node: '>=20.6.1'} - - '@netlify/edge-functions@3.0.3': - resolution: {integrity: sha512-grElRK+rTBdYrPsULPKrhcHhrW+fwpDRLPbGByqa6Xrz0fhzcFJ2D9ijxEQ/onFcSVPYHT1u1mI48GhS5bZ/Ag==} - engines: {node: '>=18.0.0'} - - '@netlify/functions-dev@1.1.5': - resolution: {integrity: sha512-7tlgf87MtqvhXrzWdlqwlked/MOIwWFw8pvzY3qoEBiKzDgCY+WSjRcGQbL1tGGB3611Xggqe+ydqU/dMvvCNQ==} - engines: {node: '>=20.6.1'} - - '@netlify/functions@5.1.1': - resolution: {integrity: sha512-64TvwQkAFpYb3QqYemPYDqWi1xMbYOBfg70bhy23iahWf+F9TJgOOnAVUOk5fMWGN/fk9bZG5ROc+cm32whh+g==} - engines: {node: '>=18.0.0'} - - '@netlify/headers-parser@9.0.2': - resolution: {integrity: sha512-86YEGPxVemhksY1LeSr8NSOyH11RHvYHq+FuBJnTlPZoRDX+TD+0TAxF6lwzAgVTd1VPkyFEHlNgUGqw7aNzRQ==} - engines: {node: '>=18.14.0'} - - '@netlify/headers@2.1.3': - resolution: {integrity: sha512-jVjhHokAQLGI5SJA2nj8OWeNQ7ASV4m0n4aiR4PHrhM8ot385V2BbUGkSpC28M92uqP0l1cbAQaSoSOU4re8iQ==} - engines: {node: '>=20.6.1'} - - '@netlify/images@1.3.3': - resolution: {integrity: sha512-1X3fUmacCLMlPIqyeV5tdo6Wbf9aBSWobgr4DyRvg9zDV9jbKqgdN3BNbcUXmVaqfN+0iiv0k9p02mcRV3OyOw==} - engines: {node: '>=20.6.1'} - - '@netlify/open-api@2.45.0': - resolution: {integrity: sha512-kLysr2N8HQi0qoEq04vpRvrE/fSnZaXJYf1bVxKre2lLaM1RSm05hqDswKTgxM601pZf9h1i1Ea3L4DZNgHb5w==} - engines: {node: '>=14.8.0'} - - '@netlify/otel@5.1.1': - resolution: {integrity: sha512-WCSlOsd0a0Vn+iPC5PYru7rq/5/QpBGnvam6C7cq9DEiTFqfwExNoxk6SWI0T6nI56gkBryaGsENLTEnUue1lg==} - engines: {node: ^18.14.0 || >=20.6.1} - - '@netlify/redirect-parser@15.0.3': - resolution: {integrity: sha512-/HB3fcRRNgf6O/pbLn4EYNDHrU2kiadMMnazg8/OjvQK2S9i4y61vQcrICvDxYKUKQdgeEaABUuaCNAJFnfD9w==} - engines: {node: '>=18.14.0'} - - '@netlify/redirects@3.1.4': - resolution: {integrity: sha512-2FcF/0Q24JA+VmpWlVRp835UvhBHQe3XGVaxAQfHiDd5aXztaz2U5Y4VEZyrZJOubY5xnxr2yqumDfClAiCKxw==} - engines: {node: '>=20.6.1'} - - '@netlify/runtime-utils@2.2.1': - resolution: {integrity: sha512-dyJeuggzQM8+Dsi0T8Z9UjfLJ6vCmNC36W6WE2aqzfTdTw4wPkh2xlEu4LoD75+TGuYK7jIhEoU2QcCXOzfyAQ==} - engines: {node: ^18.14.0 || >=20} - - '@netlify/runtime@4.1.12': - resolution: {integrity: sha512-JDIf0MA+cYGkBj6jrth7hBrHHA/1v6BMtf2QaXFAW0stiGeTG6yLXAg53ARzKiMkT8K8IIC0mggl8cjMb4eHJQ==} - engines: {node: '>=20.6.1'} - - '@netlify/serverless-functions-api@2.8.2': - resolution: {integrity: sha512-JoesbwNZ6l7D7LDmom0Ae35j1nBORd/nht6dI5ULWW9YeI6Df9C84zmBytdRcY2KafsU1l859UGa6O7nBKxT6Q==} - engines: {node: '>=18.0.0'} - - '@netlify/static@3.1.3': - resolution: {integrity: sha512-88VG2jwWY1eOT/IiMbkrak7qyo+t7om0v731i63JiCDfXjCEp+yFPNr9L4v8S6wcCmgnkGQ6Sr5roF1sEtp6+Q==} - engines: {node: '>=20.6.1'} - - '@netlify/types@2.3.0': - resolution: {integrity: sha512-5gxMWh/S7wr0uHKSTbMv4bjWmWSpwpeLYvErWeVNAPll5/QNFo9aWimMAUuh8ReLY3/fg92XAroVVu7+z27Snw==} - engines: {node: ^18.14.0 || >=20} - - '@netlify/vite-plugin@2.7.17': - resolution: {integrity: sha512-cP1e3rv0cZ5xXRSm2bdtZ0sYbcIxJQBgSg8cryXMtG689l8s/BNHj/QtOcoIFis6WEUCFHULF3bSSiaMr+meNQ==} - engines: {node: ^20.6.1 || >=22} - peerDependencies: - vite: ^5 || ^6 || ^7 - - '@netlify/zip-it-and-ship-it@14.1.17': - resolution: {integrity: sha512-dUS5trufC+tZivmzzaNStls8nbrJQqSdS75hzvUYmwHiLsmWCrhLOwAWyxj3Sa5E26YhJaI4TPiRngFTxHaSWA==} - engines: {node: '>=18.14.0'} - hasBin: true - '@nodelib/fs.scandir@2.1.5': resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} engines: {node: '>= 8'} @@ -2526,189 +2100,59 @@ packages: resolution: {integrity: sha512-kmx1hRJlsvxiTCpK97off59LqSEOtkWOPe4rdfFL8TjZtihYSTVNObIfc86jtLngfnuIuuTRt+TUCgRS220RSQ==} engines: {node: '>=20.0'} - '@opentelemetry/api-logs@0.203.0': - resolution: {integrity: sha512-9B9RU0H7Ya1Dx/Rkyc4stuBZSGVQF27WigitInx2QQoj6KUpEFYPKoWjdFTunJYxmXmh17HeBvbMa1EhGyPmqQ==} - engines: {node: '>=8.0.0'} + '@oxc-project/types@0.103.0': + resolution: {integrity: sha512-bkiYX5kaXWwUessFRSoXFkGIQTmc6dLGdxuRTrC+h8PSnIdZyuXHHlLAeTmOue5Br/a0/a7dHH0Gca6eXn9MKg==} - '@opentelemetry/api@1.9.0': - resolution: {integrity: sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg==} - engines: {node: '>=8.0.0'} + '@oxc-project/types@0.98.0': + resolution: {integrity: sha512-Vzmd6FsqVuz5HQVcRC/hrx7Ujo3WEVeQP7C2UNP5uy1hUY4SQvMB+93jxkI1KRHz9a/6cni3glPOtvteN+zpsw==} - '@opentelemetry/context-async-hooks@1.30.1': - resolution: {integrity: sha512-s5vvxXPVdjqS3kTLKMeBMvop9hbWkwzBpu+mUO2M7sZtlkyDJGwFe33wRKnbaYDo8ExRVBIIdwIGrqpxHuKttA==} - engines: {node: '>=14'} - peerDependencies: - '@opentelemetry/api': '>=1.0.0 <1.10.0' + '@photonjs/cloudflare@0.1.13': + resolution: {integrity: sha512-gyu26ZIEJTLVU47U3OC7iqsT6tvp5qpk1KtTT0zCGpTInTc5p7s3db7xAzq+egZ09SSrU+SbQpoYAlAboLaryA==} - '@opentelemetry/core@1.30.1': - resolution: {integrity: sha512-OOCM2C/QIURhJMuKaekP3TRBxBKxG/TWWA0TL2J6nXUtDnuCtccy49LUJF8xPFXMX+0LMcxFpCo8M9cGY1W6rQ==} - engines: {node: '>=14'} + '@photonjs/core@0.1.21': + resolution: {integrity: sha512-dfAUHhWGsKYPNAKqBaOfvGPKOm6l80yWJ3dq1vSG4GICa5ZJemM1xK5JRJhT1lZD4rEHPOJfQncZ8LHiMPivcg==} peerDependencies: - '@opentelemetry/api': '>=1.0.0 <1.10.0' + vite: '>=7.1' + peerDependenciesMeta: + vite: + optional: true - '@opentelemetry/instrumentation@0.203.0': - resolution: {integrity: sha512-ke1qyM+3AK2zPuBPb6Hk/GCsc5ewbLvPNkEuELx/JmANeEp6ZjnZ+wypPAJSucTw0wvCGrUaibDSdcrGFoWxKQ==} - engines: {node: ^18.19.0 || >=20.6.0} + '@photonjs/vercel@0.1.22': + resolution: {integrity: sha512-D+1rl94Jh/d54TwoMf+h9VlV3ITRt18Tdxc9BepSIIc7/tqHm88K9bPBzrAVQ7I+clI/0o2N7ZVVkp1hqDASQQ==} peerDependencies: - '@opentelemetry/api': ^1.3.0 + '@photonjs/core': ^0.1.20 + '@photonjs/runtime': ^0.1.16 + vite: '>=7.1' - '@opentelemetry/propagator-b3@1.30.1': - resolution: {integrity: sha512-oATwWWDIJzybAZ4pO76ATN5N6FFbOA1otibAVlS8v90B4S1wClnhRUk7K+2CHAwN1JKYuj4jh/lpCEG5BAqFuQ==} - engines: {node: '>=14'} - peerDependencies: - '@opentelemetry/api': '>=1.0.0 <1.10.0' + '@pinojs/redact@0.4.0': + resolution: {integrity: sha512-k2ENnmBugE/rzQfEcdWHcCY+/FM3VLzH9cYEsbdsoqrvzAKRhUZeRNhAZvB8OitQJ1TBed3yqWtdjzS6wJKBwg==} - '@opentelemetry/propagator-jaeger@1.30.1': - resolution: {integrity: sha512-Pj/BfnYEKIOImirH76M4hDaBSx6HyZ2CXUqk+Kj02m6BB80c/yo4BdWkn/1gDFfU+YPY+bPR2U0DKBfdxCKwmg==} + '@pkgjs/parseargs@0.11.0': + resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} engines: {node: '>=14'} - peerDependencies: - '@opentelemetry/api': '>=1.0.0 <1.10.0' - '@opentelemetry/resources@1.30.1': - resolution: {integrity: sha512-5UxZqiAgLYGFjS4s9qm5mBVo433u+dSPUFWVWXmLAD4wB65oMCoXaJP1KJa9DIYYMeHu3z4BZcStG3LC593cWA==} - engines: {node: '>=14'} - peerDependencies: - '@opentelemetry/api': '>=1.0.0 <1.10.0' + '@playwright/test@1.57.0': + resolution: {integrity: sha512-6TyEnHgd6SArQO8UO2OMTxshln3QMWBtPGrOCgs3wVEmQmwyuNtB10IZMfmYDE0riwNR1cu4q+pPcxMVtaG3TA==} + engines: {node: '>=18'} + hasBin: true - '@opentelemetry/sdk-trace-base@1.30.1': - resolution: {integrity: sha512-jVPgBbH1gCy2Lb7X0AVQ8XAfgg0pJ4nvl8/IiQA6nxOsPvS+0zMJaFSs2ltXe0J6C8dqjcnpyqINDJmU30+uOg==} - engines: {node: '>=14'} - peerDependencies: - '@opentelemetry/api': '>=1.0.0 <1.10.0' + '@polka/url@1.0.0-next.29': + resolution: {integrity: sha512-wwQAWhWSuHaag8c4q/KN/vCoeOJYshAIvMQwD4GpSb3OiZklFfvAgmj0VCBBImRpuF/aFgIRzllXlVX93Jevww==} - '@opentelemetry/sdk-trace-node@1.30.1': - resolution: {integrity: sha512-cBjYOINt1JxXdpw1e5MlHmFRc5fgj4GW/86vsKFxJCJ8AL4PdVtYH41gWwl4qd4uQjqEL1oJVrXkSy5cnduAnQ==} - engines: {node: '>=14'} - peerDependencies: - '@opentelemetry/api': '>=1.0.0 <1.10.0' + '@poppinss/colors@4.1.5': + resolution: {integrity: sha512-FvdDqtcRCtz6hThExcFOgW0cWX+xwSMWcRuQe5ZEb2m7cVQOAVZOIMt+/v9RxGiD9/OY16qJBXK4CVKWAPalBw==} - '@opentelemetry/semantic-conventions@1.28.0': - resolution: {integrity: sha512-lp4qAiMTD4sNWW4DbKLBkfiMZ4jbAboJIGOQr5DvciMRI494OapieI9qiODpOt0XBr1LjIDy1xAGAnVs5supTA==} - engines: {node: '>=14'} + '@poppinss/dumper@0.6.4': + resolution: {integrity: sha512-iG0TIdqv8xJ3Lt9O8DrPRxw1MRLjNpoqiSGU03P/wNLP/s0ra0udPJ1J2Tx5M0J3H/cVyEgpbn8xUKRY9j59kQ==} - '@oxc-project/types@0.103.0': - resolution: {integrity: sha512-bkiYX5kaXWwUessFRSoXFkGIQTmc6dLGdxuRTrC+h8PSnIdZyuXHHlLAeTmOue5Br/a0/a7dHH0Gca6eXn9MKg==} + '@poppinss/exception@1.2.2': + resolution: {integrity: sha512-m7bpKCD4QMlFCjA/nKTs23fuvoVFoA83brRKmObCUNmi/9tVu8Ve3w4YQAnJu4q3Tjf5fr685HYIC/IA2zHRSg==} - '@oxc-project/types@0.98.0': - resolution: {integrity: sha512-Vzmd6FsqVuz5HQVcRC/hrx7Ujo3WEVeQP7C2UNP5uy1hUY4SQvMB+93jxkI1KRHz9a/6cni3glPOtvteN+zpsw==} + '@quansync/fs@1.0.0': + resolution: {integrity: sha512-4TJ3DFtlf1L5LDMaM6CanJ/0lckGNtJcMjQ1NAV6zDmA0tEHKZtxNKin8EgPaVX1YzljbxckyT2tJrpQKAtngQ==} - '@parcel/watcher-android-arm64@2.5.1': - resolution: {integrity: sha512-KF8+j9nNbUN8vzOFDpRMsaKBHZ/mcjEjMToVMJOhTozkDonQFFrRcfdLWn6yWKCmJKmdVxSgHiYvTCef4/qcBA==} - engines: {node: '>= 10.0.0'} - cpu: [arm64] - os: [android] - - '@parcel/watcher-darwin-arm64@2.5.1': - resolution: {integrity: sha512-eAzPv5osDmZyBhou8PoF4i6RQXAfeKL9tjb3QzYuccXFMQU0ruIc/POh30ePnaOyD1UXdlKguHBmsTs53tVoPw==} - engines: {node: '>= 10.0.0'} - cpu: [arm64] - os: [darwin] - - '@parcel/watcher-darwin-x64@2.5.1': - resolution: {integrity: sha512-1ZXDthrnNmwv10A0/3AJNZ9JGlzrF82i3gNQcWOzd7nJ8aj+ILyW1MTxVk35Db0u91oD5Nlk9MBiujMlwmeXZg==} - engines: {node: '>= 10.0.0'} - cpu: [x64] - os: [darwin] - - '@parcel/watcher-freebsd-x64@2.5.1': - resolution: {integrity: sha512-SI4eljM7Flp9yPuKi8W0ird8TI/JK6CSxju3NojVI6BjHsTyK7zxA9urjVjEKJ5MBYC+bLmMcbAWlZ+rFkLpJQ==} - engines: {node: '>= 10.0.0'} - cpu: [x64] - os: [freebsd] - - '@parcel/watcher-linux-arm-glibc@2.5.1': - resolution: {integrity: sha512-RCdZlEyTs8geyBkkcnPWvtXLY44BCeZKmGYRtSgtwwnHR4dxfHRG3gR99XdMEdQ7KeiDdasJwwvNSF5jKtDwdA==} - engines: {node: '>= 10.0.0'} - cpu: [arm] - os: [linux] - - '@parcel/watcher-linux-arm-musl@2.5.1': - resolution: {integrity: sha512-6E+m/Mm1t1yhB8X412stiKFG3XykmgdIOqhjWj+VL8oHkKABfu/gjFj8DvLrYVHSBNC+/u5PeNrujiSQ1zwd1Q==} - engines: {node: '>= 10.0.0'} - cpu: [arm] - os: [linux] - - '@parcel/watcher-linux-arm64-glibc@2.5.1': - resolution: {integrity: sha512-LrGp+f02yU3BN9A+DGuY3v3bmnFUggAITBGriZHUREfNEzZh/GO06FF5u2kx8x+GBEUYfyTGamol4j3m9ANe8w==} - engines: {node: '>= 10.0.0'} - cpu: [arm64] - os: [linux] - - '@parcel/watcher-linux-arm64-musl@2.5.1': - resolution: {integrity: sha512-cFOjABi92pMYRXS7AcQv9/M1YuKRw8SZniCDw0ssQb/noPkRzA+HBDkwmyOJYp5wXcsTrhxO0zq1U11cK9jsFg==} - engines: {node: '>= 10.0.0'} - cpu: [arm64] - os: [linux] - - '@parcel/watcher-linux-x64-glibc@2.5.1': - resolution: {integrity: sha512-GcESn8NZySmfwlTsIur+49yDqSny2IhPeZfXunQi48DMugKeZ7uy1FX83pO0X22sHntJ4Ub+9k34XQCX+oHt2A==} - engines: {node: '>= 10.0.0'} - cpu: [x64] - os: [linux] - - '@parcel/watcher-linux-x64-musl@2.5.1': - resolution: {integrity: sha512-n0E2EQbatQ3bXhcH2D1XIAANAcTZkQICBPVaxMeaCVBtOpBZpWJuf7LwyWPSBDITb7In8mqQgJ7gH8CILCURXg==} - engines: {node: '>= 10.0.0'} - cpu: [x64] - os: [linux] - - '@parcel/watcher-wasm@2.5.1': - resolution: {integrity: sha512-RJxlQQLkaMMIuWRozy+z2vEqbaQlCuaCgVZIUCzQLYggY22LZbP5Y1+ia+FD724Ids9e+XIyOLXLrLgQSHIthw==} - engines: {node: '>= 10.0.0'} - bundledDependencies: - - napi-wasm - - '@parcel/watcher-win32-arm64@2.5.1': - resolution: {integrity: sha512-RFzklRvmc3PkjKjry3hLF9wD7ppR4AKcWNzH7kXR7GUe0Igb3Nz8fyPwtZCSquGrhU5HhUNDr/mKBqj7tqA2Vw==} - engines: {node: '>= 10.0.0'} - cpu: [arm64] - os: [win32] - - '@parcel/watcher-win32-ia32@2.5.1': - resolution: {integrity: sha512-c2KkcVN+NJmuA7CGlaGD1qJh1cLfDnQsHjE89E60vUEMlqduHGCdCLJCID5geFVM0dOtA3ZiIO8BoEQmzQVfpQ==} - engines: {node: '>= 10.0.0'} - cpu: [ia32] - os: [win32] - - '@parcel/watcher-win32-x64@2.5.1': - resolution: {integrity: sha512-9lHBdJITeNR++EvSQVUcaZoWupyHfXe1jZvGZ06O/5MflPcuPLtEphScIBL+AiCWBO46tDSHzWyD0uDmmZqsgA==} - engines: {node: '>= 10.0.0'} - cpu: [x64] - os: [win32] - - '@parcel/watcher@2.5.1': - resolution: {integrity: sha512-dfUnCxiN9H4ap84DvD2ubjw+3vUNpstxa0TneY/Paat8a3R4uQZDLSvWjmznAY/DoahqTHl9V46HF/Zs3F29pg==} - engines: {node: '>= 10.0.0'} - - '@pinojs/redact@0.4.0': - resolution: {integrity: sha512-k2ENnmBugE/rzQfEcdWHcCY+/FM3VLzH9cYEsbdsoqrvzAKRhUZeRNhAZvB8OitQJ1TBed3yqWtdjzS6wJKBwg==} - - '@pkgjs/parseargs@0.11.0': - resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==} - engines: {node: '>=14'} - - '@playwright/test@1.57.0': - resolution: {integrity: sha512-6TyEnHgd6SArQO8UO2OMTxshln3QMWBtPGrOCgs3wVEmQmwyuNtB10IZMfmYDE0riwNR1cu4q+pPcxMVtaG3TA==} - engines: {node: '>=18'} - hasBin: true - - '@polka/url@1.0.0-next.29': - resolution: {integrity: sha512-wwQAWhWSuHaag8c4q/KN/vCoeOJYshAIvMQwD4GpSb3OiZklFfvAgmj0VCBBImRpuF/aFgIRzllXlVX93Jevww==} - - '@poppinss/colors@4.1.5': - resolution: {integrity: sha512-FvdDqtcRCtz6hThExcFOgW0cWX+xwSMWcRuQe5ZEb2m7cVQOAVZOIMt+/v9RxGiD9/OY16qJBXK4CVKWAPalBw==} - - '@poppinss/dumper@0.6.4': - resolution: {integrity: sha512-iG0TIdqv8xJ3Lt9O8DrPRxw1MRLjNpoqiSGU03P/wNLP/s0ra0udPJ1J2Tx5M0J3H/cVyEgpbn8xUKRY9j59kQ==} - - '@poppinss/exception@1.2.2': - resolution: {integrity: sha512-m7bpKCD4QMlFCjA/nKTs23fuvoVFoA83brRKmObCUNmi/9tVu8Ve3w4YQAnJu4q3Tjf5fr685HYIC/IA2zHRSg==} - - '@quansync/fs@1.0.0': - resolution: {integrity: sha512-4TJ3DFtlf1L5LDMaM6CanJ/0lckGNtJcMjQ1NAV6zDmA0tEHKZtxNKin8EgPaVX1YzljbxckyT2tJrpQKAtngQ==} - - '@remix-run/node-fetch-server@0.8.1': - resolution: {integrity: sha512-J1dev372wtJqmqn9U/qbpbZxbJSQrogNN2+Qv1lKlpATpe/WQ9aCZfl/xSb9d2Rgh1IyLSvNxZAXPZxruO6Xig==} + '@remix-run/node-fetch-server@0.8.1': + resolution: {integrity: sha512-J1dev372wtJqmqn9U/qbpbZxbJSQrogNN2+Qv1lKlpATpe/WQ9aCZfl/xSb9d2Rgh1IyLSvNxZAXPZxruO6Xig==} '@rolldown/binding-android-arm64@1.0.0-beta.51': resolution: {integrity: sha512-Ctn8FUXKWWQI9pWC61P1yumS9WjQtelNS9riHwV7oCkknPGaAry4o7eFx2KgoLMnI2BgFJYpW7Im8/zX3BuONg==} @@ -3014,9 +2458,6 @@ packages: resolution: {integrity: sha512-7F/yz2IphV39hiS2zB4QYVkivrptHHh0K8qJJd9HhuWSdvf8AN7NpebW3CcDZDBQsUPMoDKWsY2WWgW7bqOcfA==} engines: {node: '>=18'} - '@so-ric/colorspace@1.1.6': - resolution: {integrity: sha512-/KiKkpHNOBgkFJwu9sh48LkHSMYGyuTcSFK/qMBdnOAlrRJzRSXAOFB5qwzaVQuDl8wAvHVMkaASQDReTahxuw==} - '@solid-primitives/event-listener@2.4.3': resolution: {integrity: sha512-h4VqkYFv6Gf+L7SQj+Y6puigL/5DIi7x5q07VZET7AWcS+9/G3WfIE9WheniHWJs51OEkRB43w6lDys5YeFceg==} peerDependencies: @@ -3439,21 +2880,6 @@ packages: '@tokenizer/token@0.3.0': resolution: {integrity: sha512-OvjF+z51L3ov0OyAU0duzsYuvO01PH7x4t6DJx+guahgTnBHkhJdG7soQeTSFLWN3efnHyibZ4Z8l2EuWwJN3A==} - '@ts-morph/common@0.11.1': - resolution: {integrity: sha512-7hWZS0NRpEsNV8vWJzg7FEz6V8MaLNeJOmwmghqUXTpzk16V1LLZhdo+4QvE/+zv4cVci0OviuJFnqhEfoV3+g==} - - '@tsconfig/node10@1.0.11': - resolution: {integrity: sha512-DcRjDCujK/kCk/cUe8Xz8ZSpm8mS3mNNpta+jGCA6USEDfktlNvm1+IuZ9eTcDbNk41BHwpHHeW+N1lKCz4zOw==} - - '@tsconfig/node12@1.0.11': - resolution: {integrity: sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==} - - '@tsconfig/node14@1.0.3': - resolution: {integrity: sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==} - - '@tsconfig/node16@1.0.4': - resolution: {integrity: sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==} - '@tybys/wasm-util@0.10.1': resolution: {integrity: sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==} @@ -3511,9 +2937,6 @@ packages: '@types/http-errors@2.0.5': resolution: {integrity: sha512-r8Tayk8HJnX0FztbZN7oVqGccWgw98T/0neJphO91KkmOzug1KkofZURD4UaD5uH8AqcFLfdPErnBod0u71/qg==} - '@types/json-schema@7.0.15': - resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} - '@types/mdast@4.0.4': resolution: {integrity: sha512-kGaNbPh1k7AFzgpud/gMdvIm5xuECykRR+JnWKQno9TAXVa6WIVCGTPvYGekIDL4uwCZQSYbUxNBSb1aUo79oA==} @@ -3526,18 +2949,9 @@ packages: '@types/node@12.20.55': resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} - '@types/node@16.18.11': - resolution: {integrity: sha512-3oJbGBUWuS6ahSnEq1eN2XrCyf4YsWI8OyCvo7c64zQJNplk3mO84t53o8lfTk+2ji59g5ycfc6qQ3fdHliHuA==} - - '@types/node@20.19.25': - resolution: {integrity: sha512-ZsJzA5thDQMSQO788d7IocwwQbI8B5OPzmqNvpf3NY/+MHDAS759Wo0gd2WQeXYt5AAAQjzcrTVC6SKCuYgoCQ==} - '@types/node@22.19.1': resolution: {integrity: sha512-LCCV0HdSZZZb34qifBsyWlUmok6W7ouER+oQIGBScS8EsZsQbrtFTUrDX4hOl+CS6p7cnNC4td+qrSVGSCTUfQ==} - '@types/normalize-package-data@2.4.4': - resolution: {integrity: sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==} - '@types/qs@6.14.0': resolution: {integrity: sha512-eOunJqu0K1923aExK6y8p6fsihYEn/BYuQ4g0CxAAgFc4b/ZLN4CrsRZ55srTdqoiLzU2B2evC+apEIxprEzkQ==} @@ -3552,56 +2966,24 @@ packages: '@types/react@19.2.7': resolution: {integrity: sha512-MWtvHrGZLFttgeEj28VXHxpmwYbor/ATPYbBfSFZEIRK0ecCFLl2Qo55z52Hss+UV9CRN7trSeq1zbgx7YDWWg==} - '@types/retry@0.12.2': - resolution: {integrity: sha512-XISRgDJ2Tc5q4TRqvgJtzsRkFYNJzZrhTdtMoGVBttwzzQJkPnS3WWTFc7kuDRoPtPakl+T+OfdEUjYJj7Jbow==} - '@types/send@1.2.0': resolution: {integrity: sha512-zBF6vZJn1IaMpg3xUF25VK3gd3l8zwE0ZLRX7dsQyQi+jp4E8mMDJNGDYnYse+bQhYwWERTxVwHpi3dMOq7RKQ==} '@types/serve-static@2.2.0': resolution: {integrity: sha512-8mam4H1NHLtu7nmtalF7eyBH14QyOASmcxHhSfEoRyr0nP/YdoesEtU+uSRvMe96TW/HPTtkoKqQLl53N7UXMQ==} - '@types/triple-beam@1.3.5': - resolution: {integrity: sha512-6WaYesThRMCl19iryMYP7/x2OVgCtbIVflDGFpWnb9irXI3UjYE4AzmYuiUKY1AJstGijoY+MgUszMgRxIYTYw==} - '@types/unist@2.0.11': resolution: {integrity: sha512-CmBKiL6NNo/OqgmMn95Fk9Whlp2mtvIv+KNpQKN2F4SjvrEesubTRWGYSg+BnWZOnlCaSTU1sMpsBOzgbYhnsA==} '@types/unist@3.0.3': resolution: {integrity: sha512-ko/gIFJRv177XgZsZcBwnqJN5x/Gien8qNOn0D5bQU/zAzVf9Zt3BlcUiLqhV9y4ARk0GbT3tnUiPNgnTXzc/Q==} - '@types/yauzl@2.10.3': - resolution: {integrity: sha512-oJoftv0LSuaDZE3Le4DbKX+KS9G36NzOeSap90UIK0yMA/NhKJhqlSGtNDORNRaIbQfzjXDrQa0ytJ6mNRGz/Q==} - - '@typescript-eslint/project-service@8.48.1': - resolution: {integrity: sha512-HQWSicah4s9z2/HifRPQ6b6R7G+SBx64JlFQpgSSHWPKdvCZX57XCbszg/bapbRsOEv42q5tayTYcEFpACcX1w==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.0.0' - - '@typescript-eslint/tsconfig-utils@8.48.1': - resolution: {integrity: sha512-k0Jhs4CpEffIBm6wPaCXBAD7jxBtrHjrSgtfCjUvPp9AZ78lXKdTR8fxyZO5y4vWNlOvYXRtngSZNSn+H53Jkw==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.0.0' - - '@typescript-eslint/types@8.48.1': - resolution: {integrity: sha512-+fZ3LZNeiELGmimrujsDCT4CRIbq5oXdHe7chLiW8qzqyPMnn1puNstCrMNVAqwcl2FdIxkuJ4tOs/RFDBVc/Q==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - - '@typescript-eslint/typescript-estree@8.48.1': - resolution: {integrity: sha512-/9wQ4PqaefTK6POVTjJaYS0bynCgzh6ClJHGSBj06XEHjkfylzB+A3qvyaXnErEZSaxhIo4YdyBgq6j4RysxDg==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - peerDependencies: - typescript: '>=4.8.4 <6.0.0' - - '@typescript-eslint/visitor-keys@8.48.1': - resolution: {integrity: sha512-BmxxndzEWhE4TIEEMBs8lP3MBWN3jFPs/p6gPm/wkv02o41hI6cq9AuSmGAaTTHPtA1FTi2jBre4A9rm5ZmX+Q==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@ungap/structured-clone@1.3.0': resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} + '@universal-deploy/store@0.0.2': + resolution: {integrity: sha512-fmNALSCBkjrpJmidLmMU5c4jWTXs/CKsgk9cDmTPZpne5+vWLqw73Smav6NT2tXbkGlG9nl8v4BNIFb1eE9wuw==} + '@universal-middleware/cloudflare@0.4.10': resolution: {integrity: sha512-ZY+N0KKoH+H+BB3wsaD5yqTiiFtX7uklPyCBqGLqEijOtZA5ZgFIExfWDjiIUjezUBAbRB8kUZ/WlPITY+hyTg==} @@ -3696,14 +3078,6 @@ packages: '@vercel/build-utils@13.2.4': resolution: {integrity: sha512-12m+8Z+wsxJUoWZ+JQqRk8v1O0ioJhGYWz+yStW8abuzfNz75QW2rRcbn0hSHuF8c7b3D2papmMdh94kSSYQEw==} - '@vercel/error-utils@2.0.3': - resolution: {integrity: sha512-CqC01WZxbLUxoiVdh9B/poPbNpY9U+tO1N9oWHwTl5YAZxcqXmmWJ8KNMFItJCUUWdY3J3xv8LvAuQv2KZ5YdQ==} - - '@vercel/nft@0.29.4': - resolution: {integrity: sha512-6lLqMNX3TuycBPABycx7A9F1bHQR7kiQln6abjFbPrf5C/05qHM9M5E4PeTE59c7z8g6vHnx1Ioihb2AQl7BTA==} - engines: {node: '>=18'} - hasBin: true - '@vercel/nft@0.30.4': resolution: {integrity: sha512-wE6eAGSXScra60N2l6jWvNtVK0m+sh873CpfZW4KI2v8EHuUQp+mSEi4T+IcdPCSEDgCdAS/7bizbhQlkjzrSA==} engines: {node: '>=18'} @@ -3714,15 +3088,9 @@ packages: engines: {node: '>=20'} hasBin: true - '@vercel/node@5.5.16': - resolution: {integrity: sha512-OoW99cfID3u45wbfOsy/Aibw55s0pzl4b4Wy77Weh690JhECFaiKeHL1GW6w8WGrObhKYDtsvYyoRJeKCm8kqA==} - '@vercel/routing-utils@5.3.1': resolution: {integrity: sha512-HlqFRdB6Dm20xgEWtEatchf9X28NifweXPdDoEGyj5ItngaiqpywtkgkuiAk3xK9eAu2oXM36wEJbDDTxMblUg==} - '@vercel/static-config@3.1.2': - resolution: {integrity: sha512-2d+TXr6K30w86a+WbMbGm2W91O0UzO5VeemZYBBUJbCjk/5FLLGIi8aV6RS2+WmaRvtcqNTn2pUA7nCOK3bGcQ==} - '@vikejs/biome-config@2.0.1': resolution: {integrity: sha512-kqVIZSWS7WCwTJYSzPnrhq3k+OdsOD67BM+lYtOaxkmoMfmtjz00ckGvFO8PxF8GJGeKTu7S/+pL6YmxC/Ht3Q==} peerDependencies: @@ -3793,34 +3161,10 @@ packages: '@vuedx/template-ast-types@0.7.1': resolution: {integrity: sha512-Mqugk/F0lFN2u9bhimH6G1kSu2hhLi2WoqgCVxrMvgxm2kDc30DtdvVGRq+UgEmKVP61OudcMtZqkUoGQeFBUQ==} - '@whatwg-node/disposablestack@0.0.6': - resolution: {integrity: sha512-LOtTn+JgJvX8WfBVJtF08TGrdjuFzGJc4mkP8EdDI8ADbvO7kiexYep1o8dwnt0okb0jYclCDXF13xU7Ge4zSw==} - engines: {node: '>=18.0.0'} - - '@whatwg-node/fetch@0.10.13': - resolution: {integrity: sha512-b4PhJ+zYj4357zwk4TTuF2nEe0vVtOrwdsrNo5hL+u1ojXNhh1FgJ6pg1jzDlwlT4oBdzfSwaBwMCtFCsIWg8Q==} - engines: {node: '>=18.0.0'} - - '@whatwg-node/node-fetch@0.8.4': - resolution: {integrity: sha512-AlKLc57loGoyYlrzDbejB9EeR+pfdJdGzbYnkEuZaGekFboBwzfVYVMsy88PMriqPI1ORpiGYGgSSWpx7a2sDA==} - engines: {node: '>=18.0.0'} - - '@whatwg-node/promise-helpers@1.3.2': - resolution: {integrity: sha512-Nst5JdK47VIl9UcGwtv2Rcgyn5lWtZ0/mhRQ4G8NN2isxpq2TO30iqHzmwoJycjWuyUfg3GFXqP/gFHXeV57IA==} - engines: {node: '>=16.0.0'} - - '@whatwg-node/server@0.10.17': - resolution: {integrity: sha512-QxI+HQfJeI/UscFNCTcSri6nrHP25mtyAMbhEri7W2ctdb3EsorPuJz7IovSgNjvKVs73dg9Fmayewx1O2xOxA==} - engines: {node: '>=18.0.0'} - abbrev@3.0.1: resolution: {integrity: sha512-AO2ac6pjRB3SJmGJo+v5/aK6Omggp6fsLrs6wN9bd35ulu4cCwaAU9+7ZhXjeqHVkaHThLuzH0nZr0YpCDhygg==} engines: {node: ^18.17.0 || >=20.5.0} - abort-controller@3.0.0: - resolution: {integrity: sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==} - engines: {node: '>=6.5'} - abstract-logging@2.0.1: resolution: {integrity: sha512-2BjRTZxTPvheOvGbBslFSYOUkr+SjPtOnrLP33f+VIWLzezQpZcqVg7ja3L4dBXmzzgwT+a029jRx5PCi3JuiA==} @@ -3842,10 +3186,6 @@ packages: resolution: {integrity: sha512-cjkyv4OtNCIeqhHrfS81QWXoCBPExR/J62oyEqepVw8WaQeSqpW2uhuLPh1m9eWhDuOo/jUXVTlifvesOWp/4A==} engines: {node: '>=0.4.0'} - acorn-walk@8.3.4: - resolution: {integrity: sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==} - engines: {node: '>=0.4.0'} - acorn@8.14.0: resolution: {integrity: sha512-cl669nCJTZBsL97OF4kUQm5g5hC2uihk0NxY3WENAC0TYdILVkAyHymAntgxGkl7K+t0cXIrH5siy5S4XkFycA==} engines: {node: '>=0.4.0'} @@ -3860,11 +3200,6 @@ packages: resolution: {integrity: sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==} engines: {node: '>= 14'} - ajv-errors@3.0.0: - resolution: {integrity: sha512-V3wD15YHfHz6y0KdhYFjyy9vWtEVALT9UrxfN3zqlI6dMioHnJrqOYfyPKol3oqrnCM9uwkcdCwkJ0WUcbLMTQ==} - peerDependencies: - ajv: ^8.0.1 - ajv-formats@3.0.1: resolution: {integrity: sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==} peerDependencies: @@ -3879,9 +3214,6 @@ packages: ajv@8.17.1: resolution: {integrity: sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==} - ajv@8.6.3: - resolution: {integrity: sha512-SMJOdDP6LqTkD0Uq8qLi+gMwSt0imXLSV080qFVwJCpH9U6Mb+SUGHAXM0KNbcBPguytWyvFxcHgMLe2D2XSpw==} - algoliasearch@5.40.0: resolution: {integrity: sha512-a9aIL2E3Z7uYUPMCmjMFFd5MWhn+ccTubEvnMy7rOTZCB62dXBJtz0R5BZ/TPuX3R9ocBsgWuAbGWQ+Ph4Fmlg==} engines: {node: '>= 14.0.0'} @@ -3918,17 +3250,6 @@ packages: resolution: {integrity: sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==} engines: {node: '>= 8'} - archiver-utils@5.0.2: - resolution: {integrity: sha512-wuLJMmIBQYCsGZgYLTy5FIB2pF6Lfb6cXMSF8Qywwk3t20zWnAi7zLcQFdKQmIB8wyZpY5ER38x08GbwtR2cLA==} - engines: {node: '>= 14'} - - archiver@7.0.1: - resolution: {integrity: sha512-ZcbTaIqJOfCc03QwD468Unz/5Ir8ATtvAHsK+FdXbDIbGfihqh9mrvdcYunQzqn4HrvWWaFyaxJhGZagaJJpPQ==} - engines: {node: '>= 14'} - - arg@4.1.3: - resolution: {integrity: sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==} - argparse@1.0.10: resolution: {integrity: sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==} @@ -3961,10 +3282,6 @@ packages: resolution: {integrity: sha512-m1Q/RaVOnTp9JxPX+F+Zn7IcLYMzM8kZofDImfsKZd8MbR+ikdOzTeztStWqfrqIxZnYWryyI9ePm3NGjnZgGw==} engines: {node: '>=20.19.0'} - ast-module-types@6.0.1: - resolution: {integrity: sha512-WHw67kLXYbZuHTmcdbIrVArCq5wxo6NEuj3hiYAWr8mwJeC+C2mMCIBIWCiDoCye/OF/xelc+teJ1ERoWmnEIA==} - engines: {node: '>=18'} - ast-types@0.16.1: resolution: {integrity: sha512-6t10qk83GOG8p0vKmaCr8eiilZwO171AvbROMtvvNiwrTly62t+7XkA8RdIIVbpMhCASAsxgAzdRSwh6nw/5Dg==} engines: {node: '>=4'} @@ -3977,20 +3294,9 @@ packages: resolution: {integrity: sha512-hsU18Ae8CDTR6Kgu9DYf0EbCr/a5iGL0rytQDobUcdpYOKokk8LEjVphnXkDkgpi0wYVsqrXuP0bZxJaTqdgoA==} engines: {node: '>= 0.4'} - async-listen@3.0.0: - resolution: {integrity: sha512-V+SsTpDqkrWTimiotsyl33ePSjA5/KrithwupuvJ6ztsqPvGv6ge4OredFhPffVXiLN/QUWvE0XcqJaYgt6fOg==} - engines: {node: '>= 14'} - - async-listen@3.0.1: - resolution: {integrity: sha512-cWMaNwUJnf37C/S5TfCkk/15MwbPRwVYALA2jtjkbHjCmAPiDXyNJy2q3p1KAZzDLHAWyarUWSujUoHR4pEgrA==} - engines: {node: '>= 14'} - async-sema@3.1.1: resolution: {integrity: sha512-tLRNUXati5MFePdAk8dw7Qt7DpxPB60ofAgn8WRhW6a2rcimZnYBP9oxHiv0OHy+Wz7kPMG+t4LGdt31+4EmGg==} - async@3.2.6: - resolution: {integrity: sha512-htCUDlxyyCLMgaM3xXg0C0LW2xqfuQ6p05pCEIsXuyQ+a1koYKTuBMzRNwmybfLgvJDMd0r1LTn4+E0Ti6C2AA==} - atomic-sleep@1.0.0: resolution: {integrity: sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ==} engines: {node: '>=8.0.0'} @@ -4002,14 +3308,6 @@ packages: avvio@9.1.0: resolution: {integrity: sha512-fYASnYi600CsH/j9EQov7lECAniYiBFiiAtBNuZYLA2leLe9qOvZzqYHFjtIj6gD2VMoMLP14834LFWvr4IfDw==} - b4a@1.7.3: - resolution: {integrity: sha512-5Q2mfq2WfGuFp3uS//0s6baOJLMoVduPYVeNmDYxu5OUA1/cBfvr2RIS7vi62LdNj/urk1hfmj867I3qt6uZ7Q==} - peerDependencies: - react-native-b4a: '*' - peerDependenciesMeta: - react-native-b4a: - optional: true - babel-dead-code-elimination@1.0.10: resolution: {integrity: sha512-DV5bdJZTzZ0zn0DC24v3jD7Mnidh6xhKa4GfKCbq3sfW8kaWhDdZjP3i81geA8T33tdYqWKw4D3fVv0CwEgKVA==} @@ -4019,27 +3317,10 @@ packages: balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} - bare-events@2.8.2: - resolution: {integrity: sha512-riJjyv1/mHLIPX4RwiK+oW9/4c3TEUeORHKefKAKnZ5kyslbN+HXowtbaVEqt4IMUB7OXlfixcs6gsFeo/jhiQ==} - peerDependencies: - bare-abort-controller: '*' - peerDependenciesMeta: - bare-abort-controller: - optional: true - - base64-js@1.5.1: - resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} - baseline-browser-mapping@2.9.15: resolution: {integrity: sha512-kX8h7K2srmDyYnXRIppo4AH/wYgzWVCs+eKr3RusRSQ5PvRYoEFmR/I0PbdTjKFAoKqp5+kbxnNTFO9jOfSVJg==} hasBin: true - better-ajv-errors@1.2.0: - resolution: {integrity: sha512-UW+IsFycygIo7bclP9h5ugkNH8EjCSgqyFB/yQ4Hqqa1OEYDtb0uFIkYE0b6+CjkgJYVM5UKI/pJPxjYe9EZlA==} - engines: {node: '>= 12.13.0'} - peerDependencies: - ajv: 4.11.8 - 8 - better-path-resolve@1.0.0: resolution: {integrity: sha512-pbnl5XzGBdrFU/wT4jqmJVPn2B6UHPBOhzMQkY/SPUPB6QtUXtmBHBIwCbXJol93mOpGMnQyP/+BB19q04xj7g==} engines: {node: '>=4'} @@ -4067,9 +3348,6 @@ packages: boolbase@1.0.0: resolution: {integrity: sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==} - brace-expansion@1.1.12: - resolution: {integrity: sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==} - brace-expansion@2.0.2: resolution: {integrity: sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==} @@ -4082,22 +3360,9 @@ packages: engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true - buffer-crc32@0.2.13: - resolution: {integrity: sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==} - - buffer-crc32@1.0.0: - resolution: {integrity: sha512-Db1SbgBS/fg/392AblrMJk97KggmvYhr4pB5ZIMTWtaivCPMWLkmb7m21cJvpvgK+J3nsU2CmmixNBZx4vFj/w==} - engines: {node: '>=8.0.0'} - - buffer-equal-constant-time@1.0.1: - resolution: {integrity: sha512-zRpUiDwd/xk6ADqPMATG8vc9VPrkck7T07OIx0gnjmJAnHnTVXNQG3vfvWNuiZIkwu9KrKdA1iJKfsfTVxE6NA==} - buffer-from@1.1.2: resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} - buffer@6.0.3: - resolution: {integrity: sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==} - bun-types@1.3.3: resolution: {integrity: sha512-z3Xwlg7j2l9JY27x5Qn3Wlyos8YAp0kKRlrePAOjgjMGS5IG6E7Jnlx736vH9UVI4wUICwwhC9anYL++XeOgTQ==} @@ -4121,9 +3386,6 @@ packages: resolution: {integrity: sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==} engines: {node: '>= 0.4'} - callsite@1.0.0: - resolution: {integrity: sha512-0vdNRFXn5q+dtOqjfFtmtlI9N2eVZ7LMyEV2iKC5mEEFvSg/69Ml6b/WU2qF8W1nLRa0wiSrDT3Y5jOHZCwKPQ==} - caniuse-lite@1.0.30001751: resolution: {integrity: sha512-A0QJhug0Ly64Ii3eIqHu5X51ebln3k4yTUkY1j8drqpWHVreg/VLijN48cZ1bYPiqOQuqpkIKnzr/Ul8V+p6Cw==} @@ -4138,10 +3400,6 @@ packages: resolution: {integrity: sha512-4zNhdJD/iOjSH0A05ea+Ke6MU5mmpQcbQsSOkgdaUMJ9zTlDTD/GYlwohmIE2u0gaxHYiVHEn1Fw9mZ/ktJWgw==} engines: {node: '>=18'} - chalk@4.1.2: - resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} - engines: {node: '>=10'} - chalk@5.6.2: resolution: {integrity: sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==} engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} @@ -4179,10 +3437,6 @@ packages: resolution: {integrity: sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw==} engines: {node: '>= 8.10.0'} - chokidar@4.0.3: - resolution: {integrity: sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==} - engines: {node: '>= 14.16.0'} - chownr@3.0.0: resolution: {integrity: sha512-+IxzY9BZOQd/XuYPRmrvEVjF/nqj5kgT4kEq7VofrDoM1MxoRjEWkrCC3EtLi59TVawxTAn+orJwFQcrqEN1+g==} engines: {node: '>=18'} @@ -4191,27 +3445,10 @@ packages: resolution: {integrity: sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==} engines: {node: '>=8'} - citty@0.1.6: - resolution: {integrity: sha512-tskPPKEs8D2KPafUypv2gxwJP8h/OaJmC82QQGGDQcHvXX43xF2VDACcJVmZ0EuSxkpO9Kc4MlrA3q0+FG58AQ==} - - cjs-module-lexer@1.2.3: - resolution: {integrity: sha512-0TNiGstbQmCFwt4akjjBg5pLRTSyj/PkWQ1ZoO2zntmg9yLqSRxwEa4iCfQLGjqhiqBfOJa7W/E8wfGrTDmlZQ==} - - clipboardy@4.0.0: - resolution: {integrity: sha512-5mOlNS0mhX0707P2I0aZ2V/cmHUEO/fL7VFLqszkhUsxt7RwnmrInf/eEQKlf5GzvYeHIjT+Ov1HRfNmymlG0w==} - engines: {node: '>=18'} - - cliui@8.0.1: - resolution: {integrity: sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==} - engines: {node: '>=12'} - clsx@2.1.1: resolution: {integrity: sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==} engines: {node: '>=6'} - code-block-writer@10.1.1: - resolution: {integrity: sha512-67ueh2IRGst/51p0n6FvPrnRjAGHY5F8xdjkgrYE7DDzpJe6qA07RYQ9VcoUeo5ATOjSOiWpSL3SWBRRbempMw==} - collapse-white-space@2.1.0: resolution: {integrity: sha512-loKTxY1zCOuG4j9f6EPnuyyYkf58RnhhWTvRoZEokgB+WbdXehfjFviyOVYkqzEWz1Q5kRiZdBYS5SwxbQYwzw==} @@ -4219,63 +3456,19 @@ packages: resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} engines: {node: '>=7.0.0'} - color-convert@3.1.3: - resolution: {integrity: sha512-fasDH2ont2GqF5HpyO4w0+BcewlhHEZOFn9c1ckZdHpJ56Qb7MHhH/IcJZbBGgvdtwdwNbLvxiBEdg336iA9Sg==} - engines: {node: '>=14.6'} - color-name@1.1.4: resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} - color-name@2.1.0: - resolution: {integrity: sha512-1bPaDNFm0axzE4MEAzKPuqKWeRaT43U/hyxKPBdqTfmPF+d6n7FSoTFxLVULUJOmiLp01KjhIPPH+HrXZJN4Rg==} - engines: {node: '>=12.20'} - color-string@1.9.1: resolution: {integrity: sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==} - color-string@2.1.4: - resolution: {integrity: sha512-Bb6Cq8oq0IjDOe8wJmi4JeNn763Xs9cfrBcaylK1tPypWzyoy2G3l90v9k64kjphl/ZJjPIShFztenRomi8WTg==} - engines: {node: '>=18'} - color@4.2.3: resolution: {integrity: sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==} engines: {node: '>=12.5.0'} - color@5.0.3: - resolution: {integrity: sha512-ezmVcLR3xAVp8kYOm4GS45ZLLgIE6SPAFoduLr6hTDajwb3KZ2F46gulK3XpcwRFb5KKGCSezCBAY4Dw4HsyXA==} - engines: {node: '>=18'} - comma-separated-tokens@2.0.3: resolution: {integrity: sha512-Fu4hJdvzeylCfQPp9SGWidpzrMs7tTrlu6Vb8XGaRGck8QSNZJJp538Wrb60Lax4fPwR64ViY468OIUTbRlGZg==} - commander@10.0.1: - resolution: {integrity: sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==} - engines: {node: '>=14'} - - commander@11.1.0: - resolution: {integrity: sha512-yPVavfyCcRhmorC7rWlkHn15b4wDVgVmBA7kV4QVBsF7kv/9TKJAbAXVTxvTnwP8HHKjRCJDClKbciiYS7p0DQ==} - engines: {node: '>=16'} - - commander@12.1.0: - resolution: {integrity: sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA==} - engines: {node: '>=18'} - - commander@2.20.3: - resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} - - common-path-prefix@3.0.0: - resolution: {integrity: sha512-QE33hToZseCH3jS0qN96O/bSh3kaw/h+Tq7ngyY9eWDUnTlTNUyqfqvCXioLe5Na5jFsL78ra/wuBU4iuEgd4w==} - - compress-commons@6.0.2: - resolution: {integrity: sha512-6FqVXeETqWPoGcfzrXb37E50NP0LXT8kAMu5ooZayhWWdgEY4lBEEcbQNXtkuKQsGduxiIcI4gOTsxTmuq/bSg==} - engines: {node: '>= 14'} - - concat-map@0.0.1: - resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} - - confbox@0.1.8: - resolution: {integrity: sha512-RMtmw0iFkeR4YV+fUOSucriAQNb9g8zFR52MWCtl+cCZOFRNL6zeB395vPzFhEjjn4fMxXudmELnl/KF/WrK6w==} - confbox@0.2.2: resolution: {integrity: sha512-1NB+BKqhtNipMsov4xI/NnhCKp9XG9NamYp5PVm9klAT0fsrNPjaFICsCFhNhwZJKNh7zB/3q8qXz0E9oaMNtQ==} @@ -4291,10 +3484,6 @@ packages: resolution: {integrity: sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==} engines: {node: '>= 0.6'} - convert-hrtime@3.0.0: - resolution: {integrity: sha512-7V+KqSvMiHp8yWDuwfww06XleMWVVB9b9tURBx+G7UTADuo5hYPuowKloz4OzOqbPezxgo+fdQ1522WzPG4OeA==} - engines: {node: '>=8'} - convert-route@0.1.2: resolution: {integrity: sha512-KSp+HiFELyZGWsrderXM0EjVo8Hj2eDT2LvJXNz9vnK6BVgEvlhREkAYz1oV6bx3ulhXvOtuRyE94BovdPigCQ==} @@ -4319,29 +3508,6 @@ packages: resolution: {integrity: sha512-ei8Aos7ja0weRpFzJnEA9UHJ/7XQmqglbRwnf2ATjcB9Wq874VKH9kfjjirM6UhU2/E5fFYadylyhFldcqSidQ==} engines: {node: '>=18'} - copy-file@11.1.0: - resolution: {integrity: sha512-X8XDzyvYaA6msMyAM575CUoygY5b44QzLcGRKsK3MFmXcOvQa518dNPLsKYwkYsn72g3EiW+LE0ytd/FlqWmyw==} - engines: {node: '>=18'} - - core-util-is@1.0.3: - resolution: {integrity: sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==} - - crc-32@1.2.2: - resolution: {integrity: sha512-ROmzCKrTnOwybPcJApAA6WBWij23HVfGVNKqqrZpuyZOHqK2CwHSvpGuyt/UNNvaIjEd8X5IFGp4Mh+Ie1IHJQ==} - engines: {node: '>=0.8'} - hasBin: true - - crc32-stream@6.0.0: - resolution: {integrity: sha512-piICUB6ei4IlTv1+653yq5+KoqfBYmj9bw6LqXoOneTMDXk5nM1qt12mFW1caG3LlJXEKW1Bp0WggEmIfQB34g==} - engines: {node: '>= 14'} - - create-require@1.1.1: - resolution: {integrity: sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==} - - cron-parser@4.9.0: - resolution: {integrity: sha512-p0SaNjrHOnQeR8/VnfGbmg9te2kfyYSQ7Sc/j/6DtPL3JQvKxmjO9TSjNFpujqV3vEYYBvNNvXSxzyksBWAx1Q==} - engines: {node: '>=12.0.0'} - cross-spawn@7.0.6: resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==} engines: {node: '>= 8'} @@ -4360,10 +3526,6 @@ packages: css-select@5.2.2: resolution: {integrity: sha512-TizTzUddG/xYLA3NXodFM0fSbNizXjOKhqiQQwvhlspadZokn1KDy0NZFS0wuEubIYAV5/c1/lAr0TaaFXEXzw==} - css-tree@2.2.1: - resolution: {integrity: sha512-OA0mILzGc1kCOCSJerOeqDxDQ4HOh+G8NbOJFOTgOCzpw7fCBubk0fEyxp8AgOL/jvLgYA/uV0cMbe43ElF1JA==} - engines: {node: ^10 || ^12.20.0 || ^14.13.0 || >=15.0.0, npm: '>=7.0.0'} - css-tree@3.1.0: resolution: {integrity: sha512-0eW44TGN5SQXU1mWSkKwFstI/22X2bG1nYzZTYMAWjylYURhse752YgbE4Cx46AC+bAvI+/dYTPRk1LqSUnu6w==} engines: {node: ^10 || ^12.20.0 || ^14.13.0 || >=15.0.0} @@ -4372,13 +3534,6 @@ packages: resolution: {integrity: sha512-u/O3vwbptzhMs3L1fQE82ZSLHQQfto5gyZzwteVIEyeaY5Fc7R4dapF/BvRoSYFeqfBk4m0V1Vafq5Pjv25wvA==} engines: {node: '>= 6'} - cssfilter@0.0.10: - resolution: {integrity: sha512-FAaLDaplstoRsDR8XGYH51znUN0UY7nMc6Z9/fvE8EXGwvJE9hu7W2vHwx1+bd6gCYnln9nLbzxFTrcO9YQDZw==} - - csso@5.0.5: - resolution: {integrity: sha512-0LrrStPOdJj+SPCCrGhzryycLjwcgUSHBtxNA8aIDxf0GLsRh1cKYhB00Gd1lDOS4yGH69+SNn13+TWbVHETFQ==} - engines: {node: ^10 || ^12.20.0 || ^14.13.0 || >=15.0.0, npm: '>=7.0.0'} - cssstyle@5.3.3: resolution: {integrity: sha512-OytmFH+13/QXONJcC75QNdMtKpceNk3u8ThBjyyYjkEcy/ekBwR1mMAuNvi3gdBPW3N5TlCzQ0WZw8H0lN/bDw==} engines: {node: '>=20'} @@ -4386,10 +3541,6 @@ packages: csstype@3.2.3: resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==} - data-uri-to-buffer@4.0.1: - resolution: {integrity: sha512-0R9ikRb668HB7QDxT1vkpuUBtqc53YyAwMwGeUFKRojY/NWKvdZ+9UYtRfGmhqNbRkTSVpMbmyhXipFFv2cb/A==} - engines: {node: '>= 12'} - data-urls@6.0.0: resolution: {integrity: sha512-BnBS08aLUM+DKamupXs3w2tJJoqU+AkaE/+6vQxi/G/DPmIZFJJp9Dkb1kM03AZx8ADehDUZgsNxju3mPXZYIA==} engines: {node: '>=20'} @@ -4415,23 +3566,12 @@ packages: supports-color: optional: true - decache@4.6.2: - resolution: {integrity: sha512-2LPqkLeu8XWHU8qNCS3kcF6sCcb5zIzvWaAHYSvPfwhdd7mHuah29NssMzrTYyHN4F5oFy2ko9OBYxegtU0FEw==} - decimal.js@10.6.0: resolution: {integrity: sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==} decode-named-character-reference@1.2.0: resolution: {integrity: sha512-c6fcElNV6ShtZXmsgNgFFV5tVX2PaV4g+MOAkb8eXHvn6sryJBrZa9r0zV6+dtTyoCKxtDy5tyQ5ZwQuidtd+Q==} - dedent@1.7.0: - resolution: {integrity: sha512-HGFtf8yhuhGhqO07SV79tRp+br4MnbdjeVxotpn1QBl30pcLLCQjX5b2295ll0fv8RKDKsmWYrl05usHM9CewQ==} - peerDependencies: - babel-plugin-macros: ^3.1.0 - peerDependenciesMeta: - babel-plugin-macros: - optional: true - deep-eql@4.1.4: resolution: {integrity: sha512-SUwdGfqdKOwxCPeVYjwSyRpJ7Z+fhpwIAtmCUdZIWZ/YP5R9WAsyuSgpLVDi9bjWoN2LXHNss/dk3urXtdQxGg==} engines: {node: '>=6'} @@ -4440,10 +3580,6 @@ packages: resolution: {integrity: sha512-h5k/5U50IJJFpzfL6nO9jaaumfjO/f2NjK/oYB2Djzm4p9L+3T9qWpZqZ2hAbLPuuYq9wrU08WQyBTL5GbPk5Q==} engines: {node: '>=6'} - deepmerge@4.3.1: - resolution: {integrity: sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A==} - engines: {node: '>=0.10.0'} - define-data-property@1.1.4: resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==} engines: {node: '>= 0.4'} @@ -4470,61 +3606,10 @@ packages: resolution: {integrity: sha512-reYkTUJAZb9gUuZ2RvVCNhVHdg62RHnJ7WJl8ftMi4diZ6NWlciOzQN88pUhSELEwflJht4oQDv0F0BMlwaYtA==} engines: {node: '>=8'} - detect-libc@1.0.3: - resolution: {integrity: sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==} - engines: {node: '>=0.10'} - hasBin: true - detect-libc@2.1.2: resolution: {integrity: sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==} engines: {node: '>=8'} - detective-amd@6.0.1: - resolution: {integrity: sha512-TtyZ3OhwUoEEIhTFoc1C9IyJIud3y+xYkSRjmvCt65+ycQuc3VcBrPRTMWoO/AnuCyOB8T5gky+xf7Igxtjd3g==} - engines: {node: '>=18'} - hasBin: true - - detective-cjs@6.0.1: - resolution: {integrity: sha512-tLTQsWvd2WMcmn/60T2inEJNhJoi7a//PQ7DwRKEj1yEeiQs4mrONgsUtEJKnZmrGWBBmE0kJ1vqOG/NAxwaJw==} - engines: {node: '>=18'} - - detective-es6@5.0.1: - resolution: {integrity: sha512-XusTPuewnSUdoxRSx8OOI6xIA/uld/wMQwYsouvFN2LAg7HgP06NF1lHRV3x6BZxyL2Kkoih4ewcq8hcbGtwew==} - engines: {node: '>=18'} - - detective-postcss@7.0.1: - resolution: {integrity: sha512-bEOVpHU9picRZux5XnwGsmCN4+8oZo7vSW0O0/Enq/TO5R2pIAP2279NsszpJR7ocnQt4WXU0+nnh/0JuK4KHQ==} - engines: {node: ^14.0.0 || >=16.0.0} - peerDependencies: - postcss: ^8.4.47 - - detective-sass@6.0.1: - resolution: {integrity: sha512-jSGPO8QDy7K7pztUmGC6aiHkexBQT4GIH+mBAL9ZyBmnUIOFbkfZnO8wPRRJFP/QP83irObgsZHCoDHZ173tRw==} - engines: {node: '>=18'} - - detective-scss@5.0.1: - resolution: {integrity: sha512-MAyPYRgS6DCiS6n6AoSBJXLGVOydsr9huwXORUlJ37K3YLyiN0vYHpzs3AdJOgHobBfispokoqrEon9rbmKacg==} - engines: {node: '>=18'} - - detective-stylus@5.0.1: - resolution: {integrity: sha512-Dgn0bUqdGbE3oZJ+WCKf8Dmu7VWLcmRJGc6RCzBgG31DLIyai9WAoEhYRgIHpt/BCRMrnXLbGWGPQuBUrnF0TA==} - engines: {node: '>=18'} - - detective-typescript@14.0.0: - resolution: {integrity: sha512-pgN43/80MmWVSEi5LUuiVvO/0a9ss5V7fwVfrJ4QzAQRd3cwqU1SfWGXJFcNKUqoD5cS+uIovhw5t/0rSeC5Mw==} - engines: {node: '>=18'} - peerDependencies: - typescript: ^5.4.4 - - detective-vue2@2.2.0: - resolution: {integrity: sha512-sVg/t6O2z1zna8a/UIV6xL5KUa2cMTQbdTIIvqNM0NIPswp52fe43Nwmbahzj3ww4D844u/vC2PYfiGLvD3zFA==} - engines: {node: '>=18'} - peerDependencies: - typescript: ^5.4.4 - - dettle@1.0.5: - resolution: {integrity: sha512-ZVyjhAJ7sCe1PNXEGveObOH9AC8QvMga3HJIghHawtG7mE4K5pW9nz/vDGAr/U7a3LWgdOzEE7ac9MURnyfaTA==} - detype@1.1.3: resolution: {integrity: sha512-uWLfJhQbLFXJE0VVHzuYfPAMFbzS7VJc96uOGZHL2Uw19H3KLdZ5J84qYUw20ia1kq4M9xiF+YCe/6lwNT8/aA==} hasBin: true @@ -4532,10 +3617,6 @@ packages: devlop@1.1.0: resolution: {integrity: sha512-RWmIqhcFf1lRYBvNmr7qTNuyCt/7/ns2jbpp1+PalgE/rDQcBT0fioSMUpJ93irlUhC5hrg4cYqe6U+0ImW0rA==} - diff@4.0.2: - resolution: {integrity: sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==} - engines: {node: '>=0.3.1'} - diff@8.0.2: resolution: {integrity: sha512-sSuxWU5j5SR9QQji/o2qMvqRNYRDOcBTgsJ/DeCf4iSN4gW+gNMXM7wFIP+fdXZxoNiAnHUTGjCr+TSWXdRDKg==} engines: {node: '>=0.3.1'} @@ -4560,14 +3641,6 @@ packages: domutils@3.2.2: resolution: {integrity: sha512-6kZKyUajlDuqlHKVX1w7gyslj9MPIXzIFiz/rGu35uC1wMi+kMhQwGhl4lt9unC9Vb9INnY9Z3/ZA3+FhASLaw==} - dot-prop@9.0.0: - resolution: {integrity: sha512-1gxPBJpI/pcjQhKgIU91II6Wkay+dLcN3M6rf2uwP8hRur3HtQXjVrdAK3sjC0piaEuxzMwjXChcETiJl47lAQ==} - engines: {node: '>=18'} - - dotenv@16.6.1: - resolution: {integrity: sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow==} - engines: {node: '>=12'} - dts-resolver@2.1.3: resolution: {integrity: sha512-bihc7jPC90VrosXNzK0LTE2cuLP6jr0Ro8jk+kMugHReJVLIpHz/xadeq3MhuwyO4TD4OA3L1Q8pBBFRc08Tsw==} engines: {node: '>=20.19.0'} @@ -4584,14 +3657,6 @@ packages: eastasianwidth@0.2.0: resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} - ecdsa-sig-formatter@1.0.11: - resolution: {integrity: sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ==} - - edge-runtime@2.5.9: - resolution: {integrity: sha512-pk+k0oK0PVXdlT4oRp4lwh+unuKB7Ng4iZ2HB+EZ7QCEQizX360Rp/F4aRpgpRgdP2ufB35N+1KppHmYjqIGSg==} - engines: {node: '>=16'} - hasBin: true - ee-first@1.1.1: resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} @@ -4623,9 +3688,6 @@ packages: resolution: {integrity: sha512-i6UzDscO/XfAcNYD75CfICkmfLedpyPDdozrLMmQc5ORaQcdMoc21OnlEylMIqI7U8eniKrPMxxtj8k0vhmJhA==} engines: {node: '>=14'} - enabled@2.0.0: - resolution: {integrity: sha512-AKrN98kuwOzMIdAizXGI86UFBoo26CL21UM763y1h/GMSJ4/OHU9k2YlsmBpyScFo/wbLzWQJBMCW4+IO3/+OQ==} - encodeurl@2.0.0: resolution: {integrity: sha512-Q0n9HRi4m6JuGIV1eFlmvJB7ZEVxu93IrMyiMsGC0lrMJMWzRgx6WGquyfQgZVb31vhGgXnfmPNNXmxnOkRBrg==} engines: {node: '>= 0.8'} @@ -4633,9 +3695,6 @@ packages: encoding-sniffer@0.2.1: resolution: {integrity: sha512-5gvq20T6vfpekVtqrYQsSCFZ1wEg5+wW0/QaZMWkFr6BqD3NfKs0rLCx4rrVlSWJeZb5NBJgVLswK/w2MWU+Gw==} - end-of-stream@1.4.5: - resolution: {integrity: sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==} - enhanced-resolve@5.18.3: resolution: {integrity: sha512-d4lC8xfavMeBjzGr2vECC3fsGXziXZQyJxD868h2M/mBI3PwAuODxAkLkq5HYuvrPYcUtiLzsTo8U3PgX3Ocww==} engines: {node: '>=10.13.0'} @@ -4652,10 +3711,6 @@ packages: resolution: {integrity: sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==} engines: {node: '>=0.12'} - env-paths@3.0.0: - resolution: {integrity: sha512-dtJUTepzMW3Lm/NPxRf3wP4642UWhjL2sQxc+ym2YMj1m/H2zDNQOlezafzkHwn6sMstjHTwG6iQQsctDW/b1A==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - error-stack-parser-es@1.0.5: resolution: {integrity: sha512-5qucVt2XcuGMcEGgWI7i+yZpmpByQ8J1lHhcL7PwqCwu9FPP3VUXzT4ltHe5i2z9dePwEHcDVOAfSnHsOlCXRA==} @@ -4671,9 +3726,6 @@ packages: resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} engines: {node: '>= 0.4'} - es-module-lexer@1.4.1: - resolution: {integrity: sha512-cXLGjP0c4T3flZJKQSuziYoq7MlT+rnvfZjfp7h+I7K9BNX54kP9nyWvdbwjQ4u1iWbOL4u96fgeZLToQlZC7w==} - es-module-lexer@1.7.0: resolution: {integrity: sha512-jEQoCwk8hyb2AZziIOLhDqpm5+2ww5uIE6lkO/6jcOCusfk6LhMHpXXfBLXTZ7Ydyt0j4VoUQv6uGNYbdW+kBA==} @@ -4689,145 +3741,20 @@ packages: resolution: {integrity: sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==} engines: {node: '>= 0.4'} - esbuild-android-64@0.14.47: - resolution: {integrity: sha512-R13Bd9+tqLVFndncMHssZrPWe6/0Kpv2/dt4aA69soX4PRxlzsVpCvoJeFE8sOEoeVEiBkI0myjlkDodXlHa0g==} - engines: {node: '>=12'} - cpu: [x64] - os: [android] + esbuild@0.23.1: + resolution: {integrity: sha512-VVNz/9Sa0bs5SELtn3f7qhJCDPCF5oMEl5cO9/SSinpE9hbPVvxbd572HH5AKiP7WD8INO53GgfDDhRjkylHEg==} + engines: {node: '>=18'} + hasBin: true - esbuild-android-arm64@0.14.47: - resolution: {integrity: sha512-OkwOjj7ts4lBp/TL6hdd8HftIzOy/pdtbrNA4+0oVWgGG64HrdVzAF5gxtJufAPOsEjkyh1oIYvKAUinKKQRSQ==} - engines: {node: '>=12'} - cpu: [arm64] - os: [android] + esbuild@0.25.12: + resolution: {integrity: sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==} + engines: {node: '>=18'} + hasBin: true - esbuild-darwin-64@0.14.47: - resolution: {integrity: sha512-R6oaW0y5/u6Eccti/TS6c/2c1xYTb1izwK3gajJwi4vIfNs1s8B1dQzI1UiC9T61YovOQVuePDcfqHLT3mUZJA==} - engines: {node: '>=12'} - cpu: [x64] - os: [darwin] - - esbuild-darwin-arm64@0.14.47: - resolution: {integrity: sha512-seCmearlQyvdvM/noz1L9+qblC5vcBrhUaOoLEDDoLInF/VQ9IkobGiLlyTPYP5dW1YD4LXhtBgOyevoIHGGnw==} - engines: {node: '>=12'} - cpu: [arm64] - os: [darwin] - - esbuild-freebsd-64@0.14.47: - resolution: {integrity: sha512-ZH8K2Q8/Ux5kXXvQMDsJcxvkIwut69KVrYQhza/ptkW50DC089bCVrJZZ3sKzIoOx+YPTrmsZvqeZERjyYrlvQ==} - engines: {node: '>=12'} - cpu: [x64] - os: [freebsd] - - esbuild-freebsd-arm64@0.14.47: - resolution: {integrity: sha512-ZJMQAJQsIOhn3XTm7MPQfCzEu5b9STNC+s90zMWe2afy9EwnHV7Ov7ohEMv2lyWlc2pjqLW8QJnz2r0KZmeAEQ==} - engines: {node: '>=12'} - cpu: [arm64] - os: [freebsd] - - esbuild-linux-32@0.14.47: - resolution: {integrity: sha512-FxZOCKoEDPRYvq300lsWCTv1kcHgiiZfNrPtEhFAiqD7QZaXrad8LxyJ8fXGcWzIFzRiYZVtB3ttvITBvAFhKw==} - engines: {node: '>=12'} - cpu: [ia32] - os: [linux] - - esbuild-linux-64@0.14.47: - resolution: {integrity: sha512-nFNOk9vWVfvWYF9YNYksZptgQAdstnDCMtR6m42l5Wfugbzu11VpMCY9XrD4yFxvPo9zmzcoUL/88y0lfJZJJw==} - engines: {node: '>=12'} - cpu: [x64] - os: [linux] - - esbuild-linux-arm64@0.14.47: - resolution: {integrity: sha512-ywfme6HVrhWcevzmsufjd4iT3PxTfCX9HOdxA7Hd+/ZM23Y9nXeb+vG6AyA6jgq/JovkcqRHcL9XwRNpWG6XRw==} - engines: {node: '>=12'} - cpu: [arm64] - os: [linux] - - esbuild-linux-arm@0.14.47: - resolution: {integrity: sha512-ZGE1Bqg/gPRXrBpgpvH81tQHpiaGxa8c9Rx/XOylkIl2ypLuOcawXEAo8ls+5DFCcRGt/o3sV+PzpAFZobOsmA==} - engines: {node: '>=12'} - cpu: [arm] - os: [linux] - - esbuild-linux-mips64le@0.14.47: - resolution: {integrity: sha512-mg3D8YndZ1LvUiEdDYR3OsmeyAew4MA/dvaEJxvyygahWmpv1SlEEnhEZlhPokjsUMfRagzsEF/d/2XF+kTQGg==} - engines: {node: '>=12'} - cpu: [mips64el] - os: [linux] - - esbuild-linux-ppc64le@0.14.47: - resolution: {integrity: sha512-WER+f3+szmnZiWoK6AsrTKGoJoErG2LlauSmk73LEZFQ/iWC+KhhDsOkn1xBUpzXWsxN9THmQFltLoaFEH8F8w==} - engines: {node: '>=12'} - cpu: [ppc64] - os: [linux] - - esbuild-linux-riscv64@0.14.47: - resolution: {integrity: sha512-1fI6bP3A3rvI9BsaaXbMoaOjLE3lVkJtLxsgLHqlBhLlBVY7UqffWBvkrX/9zfPhhVMd9ZRFiaqXnB1T7BsL2g==} - engines: {node: '>=12'} - cpu: [riscv64] - os: [linux] - - esbuild-linux-s390x@0.14.47: - resolution: {integrity: sha512-eZrWzy0xFAhki1CWRGnhsHVz7IlSKX6yT2tj2Eg8lhAwlRE5E96Hsb0M1mPSE1dHGpt1QVwwVivXIAacF/G6mw==} - engines: {node: '>=12'} - cpu: [s390x] - os: [linux] - - esbuild-netbsd-64@0.14.47: - resolution: {integrity: sha512-Qjdjr+KQQVH5Q2Q1r6HBYswFTToPpss3gqCiSw2Fpq/ua8+eXSQyAMG+UvULPqXceOwpnPo4smyZyHdlkcPppQ==} - engines: {node: '>=12'} - cpu: [x64] - os: [netbsd] - - esbuild-openbsd-64@0.14.47: - resolution: {integrity: sha512-QpgN8ofL7B9z8g5zZqJE+eFvD1LehRlxr25PBkjyyasakm4599iroUpaj96rdqRlO2ShuyqwJdr+oNqWwTUmQw==} - engines: {node: '>=12'} - cpu: [x64] - os: [openbsd] - - esbuild-sunos-64@0.14.47: - resolution: {integrity: sha512-uOeSgLUwukLioAJOiGYm3kNl+1wJjgJA8R671GYgcPgCx7QR73zfvYqXFFcIO93/nBdIbt5hd8RItqbbf3HtAQ==} - engines: {node: '>=12'} - cpu: [x64] - os: [sunos] - - esbuild-windows-32@0.14.47: - resolution: {integrity: sha512-H0fWsLTp2WBfKLBgwYT4OTfFly4Im/8B5f3ojDv1Kx//kiubVY0IQunP2Koc/fr/0wI7hj3IiBDbSrmKlrNgLQ==} - engines: {node: '>=12'} - cpu: [ia32] - os: [win32] - - esbuild-windows-64@0.14.47: - resolution: {integrity: sha512-/Pk5jIEH34T68r8PweKRi77W49KwanZ8X6lr3vDAtOlH5EumPE4pBHqkCUdELanvsT14yMXLQ/C/8XPi1pAtkQ==} - engines: {node: '>=12'} - cpu: [x64] - os: [win32] - - esbuild-windows-arm64@0.14.47: - resolution: {integrity: sha512-HFSW2lnp62fl86/qPQlqw6asIwCnEsEoNIL1h2uVMgakddf+vUuMcCbtUY1i8sst7KkgHrVKCJQB33YhhOweCQ==} - engines: {node: '>=12'} - cpu: [arm64] - os: [win32] - - esbuild@0.14.47: - resolution: {integrity: sha512-wI4ZiIfFxpkuxB8ju4MHrGwGLyp1+awEHAHVpx6w7a+1pmYIq8T9FGEVVwFo0iFierDoMj++Xq69GXWYn2EiwA==} - engines: {node: '>=12'} - hasBin: true - - esbuild@0.23.1: - resolution: {integrity: sha512-VVNz/9Sa0bs5SELtn3f7qhJCDPCF5oMEl5cO9/SSinpE9hbPVvxbd572HH5AKiP7WD8INO53GgfDDhRjkylHEg==} - engines: {node: '>=18'} - hasBin: true - - esbuild@0.25.12: - resolution: {integrity: sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==} - engines: {node: '>=18'} - hasBin: true - - esbuild@0.27.0: - resolution: {integrity: sha512-jd0f4NHbD6cALCyGElNpGAOtWxSq46l9X/sWB0Nzd5er4Kz2YTm+Vl0qKFT9KUJvD8+fiO8AvoHhFvEatfVixA==} - engines: {node: '>=18'} - hasBin: true + esbuild@0.27.0: + resolution: {integrity: sha512-jd0f4NHbD6cALCyGElNpGAOtWxSq46l9X/sWB0Nzd5er4Kz2YTm+Vl0qKFT9KUJvD8+fiO8AvoHhFvEatfVixA==} + engines: {node: '>=18'} + hasBin: true esbuild@0.27.2: resolution: {integrity: sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==} @@ -4845,24 +3772,11 @@ packages: resolution: {integrity: sha512-/veY75JbMK4j1yjvuUxuVsiS/hr/4iHs9FTT6cgTexxdE0Ly/glccBAkloH/DofkjRbZU3bnoj38mOmhkZ0lHw==} engines: {node: '>=12'} - escodegen@2.1.0: - resolution: {integrity: sha512-2NlIDTwUWJN0mRPQOdtQBzbUHvdGY2P1VXSyU83Q3xKxM7WHX2Ql8dKq782Q9TgQUNOLEzEYu9bzLNj1q88I5w==} - engines: {node: '>=6.0'} - hasBin: true - - eslint-visitor-keys@4.2.1: - resolution: {integrity: sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==} - engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - esprima@4.0.1: resolution: {integrity: sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==} engines: {node: '>=4'} hasBin: true - estraverse@5.3.0: - resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} - engines: {node: '>=4.0'} - estree-util-attach-comments@3.0.0: resolution: {integrity: sha512-cKUwm/HUcTDsYh/9FgnuFqpfquUbwIqwKM26BVCGDPVgvaCl/nDCCjUfiLlx6lsEZ3Z4RFxNbOQ60pkaEwFxGw==} @@ -4884,25 +3798,10 @@ packages: estree-walker@3.0.3: resolution: {integrity: sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==} - esutils@2.0.3: - resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==} - engines: {node: '>=0.10.0'} - etag@1.8.1: resolution: {integrity: sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==} engines: {node: '>= 0.6'} - event-target-shim@5.0.1: - resolution: {integrity: sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==} - engines: {node: '>=6'} - - events-universal@1.0.1: - resolution: {integrity: sha512-LUd5euvbMLpwOF8m6ivPCbhQeSiYVNb8Vs0fQ8QjXo0JTkEHpz8pxdQf0gStltaPpw0Cca8b39KxvK9cfKRiAw==} - - events@3.3.0: - resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} - engines: {node: '>=0.8.x'} - exact-mirror@0.2.2: resolution: {integrity: sha512-CrGe+4QzHZlnrXZVlo/WbUZ4qQZq8C0uATQVGVgXIrNXgHDBBNFD1VRfssRA2C9t3RYvh3MadZSdg2Wy7HBoQA==} peerDependencies: @@ -4911,10 +3810,6 @@ packages: '@sinclair/typebox': optional: true - execa@8.0.1: - resolution: {integrity: sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==} - engines: {node: '>=16.17'} - exit-hook@2.2.1: resolution: {integrity: sha512-eNTPlAD67BmP31LDINZ3U7HSF8l57TxOY2PmBJ1shpCvpnxBF93mWCE8YHBnXs8qiUZJc9WDcWIeC3a2HIAMfw==} engines: {node: '>=6'} @@ -4936,20 +3831,12 @@ packages: extendable-error@0.1.7: resolution: {integrity: sha512-UOiS2in6/Q0FK0R0q6UY9vYpQ21mr/Qn1KOnte7vsACuNJf514WvCCUHSRCPcgjPT2bAhNIJdlE6bVap1GKmeg==} - extract-zip@2.0.1: - resolution: {integrity: sha512-GDhU9ntwuKyGXdZBUgTIe+vXnWj0fppUEtMDL0+idd5Sta8TGpHssn/eusA9mrPr9qNDym6SxAYZjNvCn/9RBg==} - engines: {node: '>= 10.17.0'} - hasBin: true - fast-decode-uri-component@1.0.1: resolution: {integrity: sha512-WKgKWg5eUxvRZGwW8FvfbaH7AXSh2cL+3j5fMGzUMCxWBJ3dV3a7Wz8y2f/uQ0e3B6WmodD3oS54jTQ9HVTIIg==} fast-deep-equal@3.1.3: resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} - fast-fifo@1.3.2: - resolution: {integrity: sha512-/d9sfos4yxzpwkDkuN7k2SqFKtYNmCTzgfEpz82x34IM9/zc8KGxQoXg1liNC/izpRM/MBdt44Nmx41ZWqk+FQ==} - fast-glob@3.3.3: resolution: {integrity: sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==} engines: {node: '>=8.6.0'} @@ -4963,9 +3850,6 @@ packages: fast-querystring@1.1.2: resolution: {integrity: sha512-g6KuKWmFXc0fID8WWH0jit4g0AGBoJhCkJMb1RmbsSEUNvQ+ZC8D6CUZ+GtF8nMzSPXnhiePyyqqipzNNEnHjg==} - fast-safe-stringify@2.1.1: - resolution: {integrity: sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==} - fast-uri@3.1.0: resolution: {integrity: sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==} @@ -4982,9 +3866,6 @@ packages: fastq@1.19.1: resolution: {integrity: sha512-GwLTyxkCXjXbxqIhTsMI2Nui8huMPtnxg7krajPJAjnEG/iiOS7i+zCtWGZR9G0NBKbXKh6X9m9UIsYX/N6vvQ==} - fd-slicer@1.1.0: - resolution: {integrity: sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==} - fdir@6.5.0: resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==} engines: {node: '>=12.0.0'} @@ -4994,23 +3875,12 @@ packages: picomatch: optional: true - fecha@4.2.3: - resolution: {integrity: sha512-OP2IUU6HeYKJi3i0z4A19kHMQoLVs4Hc+DPqqxI2h/DPZHTm/vjsfC6P0b4jCMy14XizLBqvndQ+UilD7707Jw==} - - fetch-blob@3.2.0: - resolution: {integrity: sha512-7yAQpD2UMJzLi1Dqv7qFYnPbaPx7ZfFK6PiIxQ4PfkGPyNyl2Ugx+a/umUonmKqjhM4DnfbMvdX6otXq83soQQ==} - engines: {node: ^12.20 || >= 14.13} - fetchdts@0.1.7: resolution: {integrity: sha512-YoZjBdafyLIop9lSxXVI33oLD5kN31q4Td+CasofLLYeLXRFeOsuOw0Uo+XNRi9PZlbfdlN2GmRtm4tCEQ9/KA==} fflate@0.8.2: resolution: {integrity: sha512-cPJU47OaAoCbg0pBvzsgpTPhmhqI5eJjh/JIu8tPj5q+T7iLvW/JAYUqmE7KOB4R1ZyEhzBaIQpQpardBF5z8A==} - figures@6.1.0: - resolution: {integrity: sha512-d+l3qxjSesT4V7v2fh+QnmFnUWv9lSpjarhShNTgBOfA0ttejbQUAlHLitbjkoRiDulW0OPoQPYIGhIC8ohejg==} - engines: {node: '>=18'} - file-type@21.0.0: resolution: {integrity: sha512-ek5xNX2YBYlXhiUXui3D/BXa3LdqPmoLJ7rqEx2bKJ7EAUEfmXgW0Das7Dc6Nr9MvqaOnIqiPV0mZk/r/UpNAg==} engines: {node: '>=20'} @@ -5022,10 +3892,6 @@ packages: resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} engines: {node: '>=8'} - filter-obj@6.1.0: - resolution: {integrity: sha512-xdMtCAODmPloU9qtmPcdBV9Kd27NtMse+4ayThxqIHUES5Z2S6bGpap5PpdmNM56ub7y3i1eyr+vJJIIgWGKmA==} - engines: {node: '>=18'} - finalhandler@2.1.0: resolution: {integrity: sha512-/t88Ty3d5JWQbWYgaOGCCYfXRwV1+be02WqYYlL6h0lEiUAMPM8o8qKGO01YIkOHzka2up08wvgYD0mDiI+q3Q==} engines: {node: '>= 0.8'} @@ -5034,21 +3900,10 @@ packages: resolution: {integrity: sha512-eRoFWQw+Yv2tuYlK2pjFS2jGXSxSppAs3hSQjfxVKxM5amECzIgYYc1FEI8ZmhSh/Ig+FrKEz43NLRKJjYCZVg==} engines: {node: '>=20'} - find-up-simple@1.0.1: - resolution: {integrity: sha512-afd4O7zpqHeRyg4PfDQsXmlDe2PfdHtJt6Akt8jOWaApLOZk5JXs6VMR29lz03pRe9mpykrRCYIYxaJYcfpncQ==} - engines: {node: '>=18'} - find-up@4.1.0: resolution: {integrity: sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==} engines: {node: '>=8'} - find-up@7.0.0: - resolution: {integrity: sha512-YyZM99iHrqLKjmt4LJDj58KI+fYyufRLBSYcqycxf//KpBk9FoewoGX0450m9nB44qrZnovzC2oeP5hUibxc/g==} - engines: {node: '>=18'} - - fn.name@1.1.0: - resolution: {integrity: sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw==} - for-each@0.3.5: resolution: {integrity: sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==} engines: {node: '>= 0.4'} @@ -5057,10 +3912,6 @@ packages: resolution: {integrity: sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==} engines: {node: '>=14'} - formdata-polyfill@4.0.10: - resolution: {integrity: sha512-buewHzMvYL29jdeQTVILecSaZKnt/RJWjoZCF5OW60Z67/GmSLBkOFM7qh1PI3zFNtJbaZL5eQu1vLfazOwj4g==} - engines: {node: '>=12.20.0'} - forwarded@0.2.0: resolution: {integrity: sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==} engines: {node: '>= 0.6'} @@ -5105,14 +3956,6 @@ packages: resolution: {integrity: sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg==} engines: {node: '>=6.9.0'} - get-amd-module-type@6.0.1: - resolution: {integrity: sha512-MtjsmYiCXcYDDrGqtNbeIYdAl85n+5mSv2r3FbzER/YV3ZILw4HNNIw34HuV5pyl0jzs6GFYU1VHVEefhgcNHQ==} - engines: {node: '>=18'} - - get-caller-file@2.0.5: - resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} - engines: {node: 6.* || 8.* || >= 10.*} - get-func-name@2.0.2: resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} @@ -5120,9 +3963,6 @@ packages: resolution: {integrity: sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==} engines: {node: '>= 0.4'} - get-port-please@3.2.0: - resolution: {integrity: sha512-I9QVvBw5U/hw3RmWpYKRumUeaDgxTPd401x364rLmWBJcOQ753eov1eTgzDqRG9bqFIfDc7gfzcQEWrUri3o1A==} - get-port@7.1.0: resolution: {integrity: sha512-QB9NKEeDg3xxVwCCwJQ9+xycaz6pBB6iQ76wiWMl1927n0Kir6alPiP+yuiICLLU4jpMe08dXfpebuQppFA2zw==} engines: {node: '>=16'} @@ -5131,14 +3971,6 @@ packages: resolution: {integrity: sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==} engines: {node: '>= 0.4'} - get-stream@5.2.0: - resolution: {integrity: sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==} - engines: {node: '>=8'} - - get-stream@8.0.1: - resolution: {integrity: sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==} - engines: {node: '>=16'} - get-symbol-description@1.1.0: resolution: {integrity: sha512-w9UMqWwJxHNOvoNzSJ2oPF5wvYcvP7jUvYzhp67yEhTi17ZDBBC1z9pTdGuzjD+EFIqLSYRweZjqfiPzQ06Ebg==} engines: {node: '>= 0.4'} @@ -5172,11 +4004,6 @@ packages: globrex@0.1.2: resolution: {integrity: sha512-uHJgbwAMwNFf5mLst7IWLNg14x1CkeqglJb/K3doi4dw6q2IvAAmM/Y81kevy83wP+Sst+nutFTYOGg3d1lsxg==} - gonzales-pe@4.3.0: - resolution: {integrity: sha512-otgSPpUmdWJ43VXyiNgEYE4luzHCL2pz4wQ0OnDluC6Eg4Ko3Vexy/SrSynglw/eR+OhkzmqFCZa/OFa/RgAOQ==} - engines: {node: '>=0.6.0'} - hasBin: true - goober@2.1.18: resolution: {integrity: sha512-2vFqsaDVIT9Gz7N6kAL++pLpp41l3PfDuusHcjnGLfR6+huZkl6ziX+zgVC3ZxpqWhzH6pyDdGrCeDhMIvwaxw==} peerDependencies: @@ -5205,10 +4032,6 @@ packages: resolution: {integrity: sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg==} engines: {node: '>= 0.4'} - has-flag@4.0.0: - resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} - engines: {node: '>=8'} - has-property-descriptors@1.0.2: resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} @@ -5259,10 +4082,6 @@ packages: hookable@5.5.3: resolution: {integrity: sha512-Yc+BQe8SvoXH1643Qez1zqLRmbA5rCL+sSmk6TVos0LWVfNIB7PGncdlId77WzLGSIB5KaWgTaNTs2lNVEI6VQ==} - hosted-git-info@7.0.2: - resolution: {integrity: sha512-puUZAUKT5m8Zzvs72XWy3HtvVbTWljRE66cP60bxJzAqf2DgICo7lYTY2IHUmLnNpjYvw5bvmoHvPc0QO2a62w==} - engines: {node: ^16.14.0 || >=18.0.0} - html-encoding-sniffer@4.0.0: resolution: {integrity: sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==} engines: {node: '>=18'} @@ -5278,10 +4097,6 @@ packages: resolution: {integrity: sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==} engines: {node: '>= 14'} - http-shutdown@1.2.2: - resolution: {integrity: sha512-S9wWkJ/VSY9/k4qcjG318bqJNruzE4HySUhFYknwmu6LBP97KLLfwNf+n4V1BHurvFNkSKLFnK/RsuUnRTf9Vw==} - engines: {iojs: '>= 1.0.0', node: '>= 0.12.0'} - https-proxy-agent@7.0.6: resolution: {integrity: sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==} engines: {node: '>= 14'} @@ -5290,10 +4105,6 @@ packages: resolution: {integrity: sha512-v/J+4Z/1eIJovEBdlV5TYj1IR+ZiohcYGRY+qN/oC9dAfKzVT023N/Bgw37hrKCoVRBvk3bqyzpr2PP5YeTMSg==} hasBin: true - human-signals@5.0.0: - resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} - engines: {node: '>=16.17.0'} - iconv-lite@0.6.3: resolution: {integrity: sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==} engines: {node: '>=0.10.0'} @@ -5309,33 +4120,10 @@ packages: resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==} engines: {node: '>= 4'} - image-meta@0.2.2: - resolution: {integrity: sha512-3MOLanc3sb3LNGWQl1RlQlNWURE5g32aUphrDyFeCsxBTk08iE3VNe4CwsUZ0Qs1X+EfX0+r29Sxdpza4B+yRA==} - - image-size@2.0.2: - resolution: {integrity: sha512-IRqXKlaXwgSMAMtpNzZa1ZAe8m+Sa1770Dhk8VkSsP9LS+iHD62Zd8FQKs8fbPiagBE7BzoFX23cxFnwshpV6w==} - engines: {node: '>=16.x'} - hasBin: true - - import-in-the-middle@1.15.0: - resolution: {integrity: sha512-bpQy+CrsRmYmoPMAE/0G33iwRqwW4ouqdRg8jgbH3aKuCtOc8lxgmYXg2dMM92CRiGP660EtBcymH/eVUpCSaA==} - import-without-cache@0.2.4: resolution: {integrity: sha512-b/Ke0y4n26ffQhkLvgBxV/NVO/QEE6AZlrMj8DYuxBWNAAu4iMQWZTFWzKcCTEmv7VQ0ae0j8KwrlGzSy8sYQQ==} engines: {node: '>=20.19.0'} - imurmurhash@0.1.4: - resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} - engines: {node: '>=0.8.19'} - - indent-string@5.0.0: - resolution: {integrity: sha512-m6FAo/spmsW2Ab2fU35JTYwtOKa2yAwXSwgjSv1TJzh4Mh7mC3lzAOVLBprb72XsTrgkEIsl7YrFNAiDiRhIGg==} - engines: {node: '>=12'} - - index-to-position@1.2.0: - resolution: {integrity: sha512-Yg7+ztRkqslMAS2iFaU+Oa4KTSidr63OsFGlOrJoW981kIYO3CGCS3wA95P1mUi/IVSJkn0D479KTJpVpvFNuw==} - engines: {node: '>=18'} - inherits@2.0.4: resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} @@ -5354,10 +4142,6 @@ packages: resolution: {integrity: sha512-Ag3wB2o37wslZS19hZqorUnrnzSkpOVy+IiiDEiTqNubEYpYuHWIf6K4psgN2ZWKExS4xhVCrRVfb/wfW8fWJA==} engines: {node: '>= 10'} - ipx@3.1.1: - resolution: {integrity: sha512-7Xnt54Dco7uYkfdAw0r2vCly3z0rSaVhEXMzPvl3FndsTVm5p26j+PO+gyinkYmcsEUvX2Rh7OGK7KzYWRu6BA==} - hasBin: true - iron-webcrypto@1.2.1: resolution: {integrity: sha512-feOM6FaSr6rEABp/eDfVseKyTMDt+KGpeB35SkVn9Tyn0CqvVsY3EwI0v5i8nMHyJnzCIQf7nsy3p41TPkJZhg==} @@ -5394,10 +4178,6 @@ packages: resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==} engines: {node: '>= 0.4'} - is-core-module@2.16.1: - resolution: {integrity: sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==} - engines: {node: '>= 0.4'} - is-data-view@1.0.2: resolution: {integrity: sha512-RKtWF8pGmS87i2D6gqQu/l7EYRlVdfzemCJN/P3UOs//x1QE7mfhvzHIApBTRf7axvT6DMGwSwBXYCT0nfB9xw==} engines: {node: '>= 0.4'} @@ -5409,11 +4189,6 @@ packages: is-decimal@2.0.1: resolution: {integrity: sha512-AAB9hiomQs5DXWcRB1rqsxGUstbRroFOPPVAomNk/3XHR5JyEZChOyTWe2oayKnsSsr/kcGqF+z6yuH6HHpN0A==} - is-docker@3.0.0: - resolution: {integrity: sha512-eljcgEDlEns/7AXFosB5K/2nCM4P7FQPkGc/DWLy5rmFEWvZayGrik1d9/QIY5nJ4f9YsVvBkA6kJpHn9rISdQ==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - hasBin: true - is-extglob@2.1.1: resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} engines: {node: '>=0.10.0'} @@ -5437,11 +4212,6 @@ packages: is-hexadecimal@2.0.1: resolution: {integrity: sha512-DgZQp241c8oO6cA1SbTEWiXeoxV42vlcJxgH+B3hi1AiqqKruZR3ZGF8In3fj4+/y/7rHvlOZLZtgJ/4ttYGZg==} - is-inside-container@1.0.0: - resolution: {integrity: sha512-KIYLCCJghfHZxqjYBE7rEy0OBuTd5xCHS7tHVgvCLkx7StIoaxwNW3hCALgEUjFfeRk+MG/Qxmp/vtETEF3tRA==} - engines: {node: '>=14.16'} - hasBin: true - is-map@2.0.3: resolution: {integrity: sha512-1Qed0/Hr2m+YqxnM09CjA2d/i6YZNfF6R2oRAOj36eUdS6qIV/huPJNSEpKbupewFs+ZsJlxsjjPbc0/afW6Lw==} engines: {node: '>= 0.4'} @@ -5450,10 +4220,6 @@ packages: resolution: {integrity: sha512-5KoIu2Ngpyek75jXodFvnafB6DJgr3u8uuK0LEZJjrU19DrMD3EVERaR8sjz8CCGgpZvxPl9SuE1GMVPFHx1mw==} engines: {node: '>= 0.4'} - is-network-error@1.3.0: - resolution: {integrity: sha512-6oIwpsgRfnDiyEDLMay/GqCl3HoAtH5+RUKW29gYkL0QA+ipzpDLA16yQs7/RHCSu+BwgbJaOUqa4A99qNVQVw==} - engines: {node: '>=16'} - is-number-object@1.1.1: resolution: {integrity: sha512-lZhclumE1G6VYD8VHe35wFaIif+CTy5SJIi5+3y4psDgWu4wPDoBhF8NxUOinEc7pHgiTsT6MaBb92rKhhD+Xw==} engines: {node: '>= 0.4'} @@ -5462,14 +4228,6 @@ packages: resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} engines: {node: '>=0.12.0'} - is-path-inside@4.0.0: - resolution: {integrity: sha512-lJJV/5dYS+RcL8uQdBDW9c9uWFLLBNRyFhnAKXw5tVqLlKZ4RMGZKv+YQ/IA3OhD+RpbJa1LLFM1FQPGyIXvOA==} - engines: {node: '>=12'} - - is-plain-obj@2.1.0: - resolution: {integrity: sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==} - engines: {node: '>=8'} - is-plain-obj@4.1.0: resolution: {integrity: sha512-+Pgi+vMuUNkJyExiMBt5IlFoMyKnr5zhJ4Uspz58WOhBF5QoIZkFyNHIbBAtHwzVAgk5RtndVNsDRN61/mmDqg==} engines: {node: '>=12'} @@ -5495,18 +4253,6 @@ packages: resolution: {integrity: sha512-ISWac8drv4ZGfwKl5slpHG9OwPNty4jOWPRIhBpxOoD+hqITiwuipOQ2bNthAzwA3B4fIjO4Nln74N0S9byq8A==} engines: {node: '>= 0.4'} - is-stream@2.0.1: - resolution: {integrity: sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==} - engines: {node: '>=8'} - - is-stream@3.0.0: - resolution: {integrity: sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - - is-stream@4.0.1: - resolution: {integrity: sha512-Dnz92NInDqYckGEUJv689RbRiTSEHCQ7wOVeALbkOz999YpqT46yMRIGtSNl2iCL1waAZSx40+h59NV/EwzV/A==} - engines: {node: '>=18'} - is-string@1.1.1: resolution: {integrity: sha512-BtEeSsoaQjlSPBemMQIrY1MY0uM6vnS1g5fmufYOtnxLGUZM2178PKbhsk7Ffv58IX+ZtcvoGwccYsh0PglkAA==} engines: {node: '>= 0.4'} @@ -5523,17 +4269,6 @@ packages: resolution: {integrity: sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==} engines: {node: '>= 0.4'} - is-unicode-supported@2.1.0: - resolution: {integrity: sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==} - engines: {node: '>=18'} - - is-url-superb@4.0.0: - resolution: {integrity: sha512-GI+WjezhPPcbM+tqE9LnmsY5qqjwHzTvjJ36wxYX5ujNXefSUJ/T17r5bqDV8yLhcgB59KTPNOc9O9cmHTPWsA==} - engines: {node: '>=10'} - - is-url@1.2.4: - resolution: {integrity: sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww==} - is-weakmap@2.0.2: resolution: {integrity: sha512-K5pXYOm9wqY1RgjpL3YTkF39tni1XajUIkawTLUo9EZEVUFga5gSQJF8nNS7ZwJQ02y+1YCNYcMh+HIf1ZqE+w==} engines: {node: '>= 0.4'} @@ -5550,17 +4285,6 @@ packages: resolution: {integrity: sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==} engines: {node: '>=0.10.0'} - is-wsl@3.1.0: - resolution: {integrity: sha512-UcVfVfaK4Sc4m7X3dUSoHoozQGBEFeDC+zVo06t98xe8CzHSZZBekNXH+tu0NalHolcJ/QAGqS46Hef7QXBIMw==} - engines: {node: '>=16'} - - is64bit@2.0.0: - resolution: {integrity: sha512-jv+8jaWCl0g2lSBkNSVXdzfBA0npK1HGC2KtWM9FumFRoGS94g3NbCCLVnCYHLjp4GrW2KZeeSTMo5ddtznmGw==} - engines: {node: '>=18'} - - isarray@1.0.0: - resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==} - isarray@2.0.5: resolution: {integrity: sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==} @@ -5581,12 +4305,6 @@ packages: jju@1.4.0: resolution: {integrity: sha512-8wb9Yw966OSxApiCt0K3yNJL8pnNeIv+OEq2YMidz4FKP6nonSRoOXc80iXY4JaN2FC11B9qsNmDsm+ZOfMROA==} - jpeg-js@0.4.4: - resolution: {integrity: sha512-WZzeDOEtTOBK4Mdsar0IqEU5sMr3vSV2RqkAIzUEV2BHnUfKGyswWFPFwK5EeDo93K3FohSHbLAjj0s1Wzd+dg==} - - js-image-generator@1.0.4: - resolution: {integrity: sha512-ckb7kyVojGAnArouVR+5lBIuwU1fcrn7E/YYSd0FK7oIngAkMmRvHASLro9Zt5SQdWToaI66NybG+OGxPw/HlQ==} - js-tokens@4.0.0: resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==} @@ -5618,9 +4336,6 @@ packages: json-schema-ref-resolver@3.0.0: resolution: {integrity: sha512-hOrZIVL5jyYFjzk7+y7n5JDzGlU8rfWDuYyHwGa2WA8/pcmMHezp2xsVwxrebD/Q9t8Nc5DboieySDpCp4WG4A==} - json-schema-to-ts@1.6.4: - resolution: {integrity: sha512-pR4yQ9DHz6itqswtHCm26mw45FSNfQ9rEQjosaZErhn5J3J2sIViQiz8rDaezjKAhFGpmsoczYVBgGHzFw/stA==} - json-schema-traverse@0.4.1: resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} @@ -5635,51 +4350,13 @@ packages: jsonfile@4.0.0: resolution: {integrity: sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==} - jsonpointer@5.0.1: - resolution: {integrity: sha512-p/nXbhSEcu3pZRdkW1OfJhpsVtW1gd4Wa1fnQc9YLiTfAjn0312eMKimbdIQzuZl9aa9xUGaRlP9T/CJE/ditQ==} - engines: {node: '>=0.10.0'} - - jsonwebtoken@9.0.2: - resolution: {integrity: sha512-PRp66vJ865SSqOlgqS8hujT5U4AOgMfhrwYIuIhfKaoSCZcirrmASQr8CX7cUg+RMih+hgznrjp99o+W4pJLHQ==} - engines: {node: '>=12', npm: '>=6'} - - junk@4.0.1: - resolution: {integrity: sha512-Qush0uP+G8ZScpGMZvHUiRfI0YBWuB3gVBYlI0v0vvOJt5FLicco+IkP0a50LqTTQhmts/m6tP5SWE+USyIvcQ==} - engines: {node: '>=12.20'} - - jwa@1.4.2: - resolution: {integrity: sha512-eeH5JO+21J78qMvTIDdBXidBd6nG2kZjg5Ohz/1fpa28Z4CcsWUzJ1ZZyFq/3z3N17aZy+ZuBoHljASbL1WfOw==} - - jws@3.2.2: - resolution: {integrity: sha512-YHlZCB6lMTllWDtSPHz/ZXTsi8S00usEV6v1tjq8tOUZzw7DpSDWVXjXDre6ed1w/pd495ODpHZYSdkRTsa0HA==} - - jwt-decode@4.0.0: - resolution: {integrity: sha512-+KJGIyHgkGuIq3IEBNftfhW/LfWhXUIY6OmyVWjliu5KH1y0fw7VQ8YndE2O4qZdMSd9SqbnC8GOcZEy0Om7sA==} - engines: {node: '>=18'} - kleur@4.1.5: resolution: {integrity: sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==} engines: {node: '>=6'} - kuler@2.0.0: - resolution: {integrity: sha512-Xq9nH7KlWZmXAtodXDDRE7vs6DU1gTU8zYDHDiWLSip45Egwq3plLHzPn27NgvzL2r1LMPC1vdqh98sQxtqj4A==} - - lambda-local@2.2.0: - resolution: {integrity: sha512-bPcgpIXbHnVGfI/omZIlgucDqlf4LrsunwoKue5JdZeGybt8L6KyJz2Zu19ffuZwIwLj2NAI2ZyaqNT6/cetcg==} - engines: {node: '>=8'} - hasBin: true - launch-editor@2.12.0: resolution: {integrity: sha512-giOHXoOtifjdHqUamwKq6c49GzBdLjvxrd2D+Q4V6uOHopJv7p9VJxikDsQ/CBXZbEITgUqSVHXLTG3VhPP1Dg==} - lazystream@1.0.1: - resolution: {integrity: sha512-b94GiNHQNy6JNTrt5w6zNyffMrNkXZb3KTkCZJb2V1xaEGCk093vkZ2jk3tpaeP33/OiXC+WvK9AxUebnf5nbw==} - engines: {node: '>= 0.6.3'} - - leven@3.1.0: - resolution: {integrity: sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==} - engines: {node: '>=6'} - light-my-request@6.6.0: resolution: {integrity: sha512-CHYbu8RtboSIoVsHZ6Ye4cj4Aw/yg2oAFimlF7mNvfDV192LR7nDiKtSIfCuLT7KokPSTn/9kfVLm5OGN0A28A==} @@ -5753,49 +4430,13 @@ packages: resolution: {integrity: sha512-utfs7Pr5uJyyvDETitgsaqSyjCb2qNRAtuqUeWIAKztsOYdcACf2KtARYXg2pSvhkt+9NfoaNY7fxjl6nuMjIQ==} engines: {node: '>= 12.0.0'} - listhen@1.9.0: - resolution: {integrity: sha512-I8oW2+QL5KJo8zXNWX046M134WchxsXC7SawLPvRQpogCbkyQIaFxPE89A2HiwR7vAK2Dm2ERBAmyjTYGYEpBg==} - hasBin: true - locate-path@5.0.0: resolution: {integrity: sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==} engines: {node: '>=8'} - locate-path@7.2.0: - resolution: {integrity: sha512-gvVijfZvn7R+2qyPX8mAuKcFGDf6Nc61GdvGafQsHL0sBIxfKzA+usWn4GFC/bk+QdwPUD4kWFJLhElipq+0VA==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - - lodash.includes@4.3.0: - resolution: {integrity: sha512-W3Bx6mdkRTGtlJISOvVD/lbqjTlPPUDTMnlXZFnVwi9NKJ6tiAk6LVdlhZMm17VZisqhKcgzpO5Wz91PCt5b0w==} - - lodash.isboolean@3.0.3: - resolution: {integrity: sha512-Bz5mupy2SVbPHURB98VAcw+aHh4vRV5IPNhILUCsOzRmsTmSQ17jIuqopAentWoehktxGd9e/hbIXq980/1QJg==} - - lodash.isinteger@4.0.4: - resolution: {integrity: sha512-DBwtEWN2caHQ9/imiNeEA5ys1JoRtRfY3d7V9wkqtbycnAmTvRRmbHKDV4a0EYc678/dia0jrte4tjYwVBaZUA==} - - lodash.isnumber@3.0.3: - resolution: {integrity: sha512-QYqzpfwO3/CWf3XP+Z+tkQsfaLL/EnUlXWVkIk5FUPc4sBdTehEqZONuyRt2P67PXAk+NXmTBcc97zw9t1FQrw==} - - lodash.isplainobject@4.0.6: - resolution: {integrity: sha512-oSXzaWypCMHkPC3NvBEaPHf0KsA5mvPrOPgQWDsbg8n7orZ290M0BmC/jgRZ4vcJ6DTAhjrsSYgdsW/F+MFOBA==} - - lodash.isstring@4.0.1: - resolution: {integrity: sha512-0wJxfxH1wgO3GrbuP+dTTk7op+6L41QCXbGINEmD+ny/G/eCqGzxyCsh7159S+mgDDcoarnBw6PC1PS5+wUGgw==} - - lodash.once@4.1.1: - resolution: {integrity: sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==} - lodash.startcase@4.4.0: resolution: {integrity: sha512-+WKqsK294HMSc2jEbNgpHpd0JfIBhp7rEV4aqXWqFr6AlXov+SlcgB1Fv01y2kGe3Gc8nMW7VA0SrGuSkRfIEg==} - lodash@4.17.21: - resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} - - logform@2.7.0: - resolution: {integrity: sha512-TFYA4jnP7PVbmlBIfhlSe+WKxs9dklXMTEGcBCIvLhE/Tn3H6Gk1norupVW7m5Cnd4bLcr08AytbyV/xj7f/kQ==} - engines: {node: '>= 12.0.0'} - longest-streak@3.1.0: resolution: {integrity: sha512-9Ri+o0JYgehTaVBBDoMqIl8GXtbWg711O3srftcHhZ0dqnETqLaoIK0x17fUw9rFSlK/0NlsKe0Ahhyl5pXE2g==} @@ -5824,10 +4465,6 @@ packages: peerDependencies: react: ^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0 - luxon@3.7.2: - resolution: {integrity: sha512-vtEhXh/gNjI9Yg1u4jX/0YVPMvxzHuGgCm6tC5kZyb08yjGWGnqAjGJvcXbqQR2P3MyMEFnRbpcdFS6PBcLqew==} - engines: {node: '>=12'} - lz-string@1.5.0: resolution: {integrity: sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ==} hasBin: true @@ -5838,13 +4475,6 @@ packages: magicast@0.5.1: resolution: {integrity: sha512-xrHS24IxaLrvuo613F719wvOIv9xPHFWQHuvGUBmPnCA/3MQxKI3b+r7n1jAoDHmsbC5bRhTZYR77invLAxVnw==} - make-error@1.3.6: - resolution: {integrity: sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==} - - map-obj@5.0.2: - resolution: {integrity: sha512-K6K2NgKnTXimT3779/4KxSvobxOtMmx1LBZ3NwRxT/MDIR3Br/fQ4Q+WCX5QxjyUR8zg5+RV9Tbf2c5pAWTD2A==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - markdown-extensions@2.0.0: resolution: {integrity: sha512-o5vL7aDWatOTX8LzaS1WMoaoxIiLRQJuIKKe2wAw6IeULDHaqbiqiggmx+pKvZDb1Sj+pE46Sn1T7lCqfFtg1Q==} engines: {node: '>=16'} @@ -5904,9 +4534,6 @@ packages: mdast-util-to-string@4.0.0: resolution: {integrity: sha512-0H44vDimn51F0YwvxSJSm0eCDOJTRlmN0R1yBh4HLj9wiV1Dn0QoXGbvFAWj2hSItVTlCmBF1hqKlIyUBVFLPg==} - mdn-data@2.0.28: - resolution: {integrity: sha512-aylIc7Z9y4yzHYAJNuESG3hfhC+0Ibp/MAMiaOZgNv4pmEdFyfZhhhny4MNiAfWdBQ1RQ2mfDWmM1x8SvGyp8g==} - mdn-data@2.12.2: resolution: {integrity: sha512-IEn+pegP1aManZuckezWCO+XZQDplx1366JoVhTpMpBB1sPey/SbveZQUosKiKiGYjg1wH4pMlNgXbCiYgihQA==} @@ -5921,13 +4548,6 @@ packages: resolution: {integrity: sha512-Snk314V5ayFLhp3fkUREub6WtjBfPdCPY1Ln8/8munuLuiYhsABgBVWsozAG+MWMbVEvcdcpbi9R7ww22l9Q3g==} engines: {node: '>=18'} - merge-options@3.0.4: - resolution: {integrity: sha512-2Sug1+knBjkaMsMgf1ctR1Ujx+Ayku4EdJN4Z+C2+JzoeF7A3OZ9KM2GY0CpQS51NR61LTurMJrRKPhSs3ZRTQ==} - engines: {node: '>=10'} - - merge-stream@2.0.0: - resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} - merge2@1.4.1: resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} engines: {node: '>= 8'} @@ -6041,18 +4661,10 @@ packages: resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} engines: {node: '>=8.6'} - mime-db@1.52.0: - resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} - engines: {node: '>= 0.6'} - mime-db@1.54.0: resolution: {integrity: sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==} engines: {node: '>= 0.6'} - mime-types@2.1.35: - resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} - engines: {node: '>= 0.6'} - mime-types@3.0.1: resolution: {integrity: sha512-xRc4oEhT6eaBpU1XF7AjpOFD+xQmXNB5OVKwp4tqCuBpHLS/ZbBDrc07mYTDqVMg6PfxUjjNp85O6Cd2Z/5HWA==} engines: {node: '>= 0.6'} @@ -6062,10 +4674,6 @@ packages: engines: {node: '>=10.0.0'} hasBin: true - mimic-fn@4.0.0: - resolution: {integrity: sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==} - engines: {node: '>=12'} - miniflare@4.20251217.0: resolution: {integrity: sha512-8xsTQbPS6YV+ABZl9qiJIbsum6hbpbhqiyKpOVdzZrhK+1N8EFpT8R6aBZff7kezGmxYZSntjgjqTwJmj3JLgA==} engines: {node: '>=18.0.0'} @@ -6075,20 +4683,10 @@ packages: resolution: {integrity: sha512-enIvLvRAFZYXJzkCYG5RKmPfrFArdLv+R+lbQ53BmIMLIry74bjKzX6iHAm8WYamJkhSSEabrWN5D97XnKObjQ==} engines: {node: 20 || >=22} - minimatch@3.1.2: - resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} - - minimatch@5.1.6: - resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} - engines: {node: '>=10'} - minimatch@9.0.5: resolution: {integrity: sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==} engines: {node: '>=16 || 14 >=14.17'} - minimist@1.2.8: - resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} - minipass@7.1.2: resolution: {integrity: sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==} engines: {node: '>=16 || 14 >=14.17'} @@ -6097,22 +4695,6 @@ packages: resolution: {integrity: sha512-KZxYo1BUkWD2TVFLr0MQoM8vUUigWD3LlD83a/75BqC+4qE0Hb1Vo5v1FgcfaNXvfXzr+5EhQ6ing/CaBijTlw==} engines: {node: '>= 18'} - mkdirp@1.0.4: - resolution: {integrity: sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==} - engines: {node: '>=10'} - hasBin: true - - mlly@1.8.0: - resolution: {integrity: sha512-l8D9ODSRWLe2KHJSifWGwBqpTZXIXTeo8mlKjY+E2HAakaTeNpqAyBZ8GSqLzHgw4XmHmC8whvpjJNMbFZN7/g==} - - module-definition@6.0.1: - resolution: {integrity: sha512-FeVc50FTfVVQnolk/WQT8MX+2WVcDnTGiq6Wo+/+lJ2ET1bRVi3HG3YlJUfqagNMc/kUlFSoR96AJkxGpKz13g==} - engines: {node: '>=18'} - hasBin: true - - module-details-from-path@1.0.4: - resolution: {integrity: sha512-EGWKgxALGMgzvxYF1UyGTy0HXX/2vHLkw6+NvDKW2jypWbHpjQuj4UMcqQWXHERJhVGKikolT06G3bcKe4fi7w==} - mri@1.2.0: resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==} engines: {node: '>=4'} @@ -6133,29 +4715,6 @@ packages: resolution: {integrity: sha512-8Ofs/AUQh8MaEcrlq5xOX0CQ9ypTF5dl78mjlMNfOK08fzpgTHQRQPBxcPlEtIw0yRpws+Zo/3r+5WRby7u3Gg==} engines: {node: '>= 0.6'} - netlify-redirector@0.5.0: - resolution: {integrity: sha512-4zdzIP+6muqPCuE8avnrgDJ6KW/2+UpHTRcTbMXCIRxiRmyrX+IZ4WSJGZdHPWF3WmQpXpy603XxecZ9iygN7w==} - - node-addon-api@7.1.1: - resolution: {integrity: sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ==} - - node-domexception@1.0.0: - resolution: {integrity: sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==} - engines: {node: '>=10.5.0'} - deprecated: Use your platform's native DOMException instead - - node-fetch-native@1.6.7: - resolution: {integrity: sha512-g9yhqoedzIUm0nTnTqAQvueMPVOuIY16bqgAJJC8XOOubYFNwz6IER9qs0Gq2Xd0+CecCKFjtdDTMA4u4xG06Q==} - - node-fetch@2.6.9: - resolution: {integrity: sha512-DJm/CJkZkRjKKj4Zi4BsKVZh3ValV5IR5s7LVZnW+6YMh0W1BfNA8XSs6DLMGYlId5F3KnA70uu2qepcR08Qqg==} - engines: {node: 4.x || >=6.0.0} - peerDependencies: - encoding: ^0.1.0 - peerDependenciesMeta: - encoding: - optional: true - node-fetch@2.7.0: resolution: {integrity: sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==} engines: {node: 4.x || >=6.0.0} @@ -6165,14 +4724,6 @@ packages: encoding: optional: true - node-fetch@3.3.2: - resolution: {integrity: sha512-dRB78srN/l6gqWulah9SrxeYnxeddIG30+GOqK/9OlLVyLg3HPnr6SqOWTWOXKRwC2eGYCkZ59NNuSgvSrpgOA==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - - node-forge@1.3.2: - resolution: {integrity: sha512-6xKiQ+cph9KImrRh0VsjH2d8/GXA4FIMlgU4B757iI1ApvcyA9VlouP0yZJha01V+huImO+kKMU7ih+2+E14fw==} - engines: {node: '>= 6.13.0'} - node-gyp-build@4.8.4: resolution: {integrity: sha512-LA4ZjwlnUblHVgq0oBF3Jl/6h/Nvs5fzBLwdEF4nuxnFdsfajde4WfxtJr3CaiH+F6ewcIB/q4jQ4UzPyid+CQ==} hasBin: true @@ -6183,35 +4734,15 @@ packages: node-releases@2.0.26: resolution: {integrity: sha512-S2M9YimhSjBSvYnlr5/+umAnPHE++ODwt5e2Ij6FoX45HA/s4vHdkDx1eax2pAPeAOqu4s9b7ppahsyEFdVqQA==} - node-source-walk@7.0.1: - resolution: {integrity: sha512-3VW/8JpPqPvnJvseXowjZcirPisssnBuDikk6JIZ8jQzF7KJQX52iPFX4RYYxLycYH7IbMRSPUOga/esVjy5Yg==} - engines: {node: '>=18'} - - node-stream-zip@1.15.0: - resolution: {integrity: sha512-LN4fydt9TqhZhThkZIVQnF9cwjU3qmUH9h78Mx/K7d3VvfRqqwthLwJEUOEL0QPZ0XQmNN7be5Ggit5+4dq3Bw==} - engines: {node: '>=0.12.0'} - nopt@8.1.0: resolution: {integrity: sha512-ieGu42u/Qsa4TFktmaKEwM6MQH0pOWnaB3htzh0JRtx84+Mebc0cbZYN5bC+6WTZ4+77xrL9Pn5m7CV6VIkV7A==} engines: {node: ^18.17.0 || >=20.5.0} hasBin: true - normalize-package-data@6.0.2: - resolution: {integrity: sha512-V6gygoYb/5EmNI+MEGrWkC+e6+Rr7mTmfHrxDbLzxQogBkgzo76rkok0Am6thgSF7Mv2nLOajAJj5vDJZEFn7g==} - engines: {node: ^16.14.0 || >=18.0.0} - - normalize-path@2.1.1: - resolution: {integrity: sha512-3pKJwH184Xo/lnH6oyP1q2pMd7HcypqqmRs91/6/i2CGtWwIKGCkOOMTm/zXbgTEWHw1uNpNi/igc3ePOYHb6w==} - engines: {node: '>=0.10.0'} - normalize-path@3.0.0: resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} engines: {node: '>=0.10.0'} - npm-run-path@5.3.0: - resolution: {integrity: sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - nth-check@2.1.1: resolution: {integrity: sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==} @@ -6230,12 +4761,6 @@ packages: obug@2.1.1: resolution: {integrity: sha512-uTqF9MuPraAQ+IsnPf366RG4cP9RtUi7MLO1N3KEc+wb0a6yKpeL0lmk2IB1jY5KHPAlTc6T/JRdC/YqxHNwkQ==} - ofetch@1.5.1: - resolution: {integrity: sha512-2W4oUZlVaqAPAil6FUg/difl6YhqhUR7x2eZY4bQCko22UXg3hptq9KLQdqFClV+Wu85UX7hNtdGTngi/1BxcA==} - - omit.js@2.0.2: - resolution: {integrity: sha512-hJmu9D+bNB40YpL9jYebQl4lsTW6yEHRTroJzNLqQJYHm7c+NQnJGfZmIWh8S3q3KoaxV1aLhV6B3+0N0/kyJg==} - on-exit-leak-free@2.1.2: resolution: {integrity: sha512-0eJJY6hXLGf1udHwfNftBqH+g73EU4B504nZeKpz1sYRKafAghwxEJunB2O7rDZkL4PGfsMVnTXZ2EjibbqcsA==} engines: {node: '>=14.0.0'} @@ -6247,13 +4772,6 @@ packages: once@1.4.0: resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} - one-time@1.0.0: - resolution: {integrity: sha512-5DXOiRKwuSEcQ/l0kGCF6Q3jcADFv5tSmRaJck/OqkVFcOzutB134KRSfF0xDrL39MNnqxbHBbUUcjZIhTgb2g==} - - onetime@6.0.0: - resolution: {integrity: sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==} - engines: {node: '>=12'} - openapi-types@12.1.3: resolution: {integrity: sha512-N4YtSYJqghVu4iek2ZUvcN/0aqH1kRDuNqzcycDxhOUpg7GdvLa2F3DgS6yBNhInhv2r/6I0Flkn7CqL8+nIcw==} @@ -6264,10 +4782,6 @@ packages: resolution: {integrity: sha512-qFOyK5PjiWZd+QQIh+1jhdb9LpxTF0qs7Pm8o5QHYZ0M3vKqSqzsZaEB6oWlxZ+q2sJBMI/Ktgd2N5ZwQoRHfg==} engines: {node: '>= 0.4'} - p-event@6.0.1: - resolution: {integrity: sha512-Q6Bekk5wpzW5qIyUP4gdMEujObYstZl6DMMOSenwBvV0BlE5LkDwkjs5yHbZmdCEq2o4RJx4tE1vwxFVf2FG1w==} - engines: {node: '>=16.17'} - p-filter@2.1.0: resolution: {integrity: sha512-ZBxxZ5sL2HghephhpGAQdoskxplTwr7ICaehZwLIlfL6acuVgZPm8yBNuRAFBGEqtD/hmUeq9eqLg2ys9Xr/yw==} engines: {node: '>=8'} @@ -6276,42 +4790,18 @@ packages: resolution: {integrity: sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==} engines: {node: '>=6'} - p-limit@4.0.0: - resolution: {integrity: sha512-5b0R4txpzjPWVw/cXXUResoD4hb6U/x9BH08L7nw+GN1sezDzPdxeRvpc9c433fZhBan/wusjbCsqwqm4EIBIQ==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - p-locate@4.1.0: resolution: {integrity: sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==} engines: {node: '>=8'} - p-locate@6.0.0: - resolution: {integrity: sha512-wPrq66Llhl7/4AGC6I+cqxT07LhXvWL08LNXz1fENOw0Ap4sRZZ/gZpTTJ5jpurzzzfS2W/Ge9BY3LgLjCShcw==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - p-map@2.1.0: resolution: {integrity: sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==} engines: {node: '>=6'} - p-map@7.0.4: - resolution: {integrity: sha512-tkAQEw8ysMzmkhgw8k+1U/iPhWNhykKnSk4Rd5zLoPJCuJaGRPo6YposrZgaxHKzDHdDWWZvE/Sk7hsL2X/CpQ==} - engines: {node: '>=18'} - - p-retry@6.2.1: - resolution: {integrity: sha512-hEt02O4hUct5wtwg4H4KcWgDdm+l1bOaEy/hWzd8xtXB9BqxTWBBhb+2ImAtH4Cv4rPjV76xN3Zumqk3k3AhhQ==} - engines: {node: '>=16.17'} - - p-timeout@6.1.4: - resolution: {integrity: sha512-MyIV3ZA/PmyBN/ud8vV9XzwTrNtR4jFrObymZYnZqMmW0zA8Z17vnT0rBgFE/TlohB+YCHqXMgZzb3Csp49vqg==} - engines: {node: '>=14.16'} - p-try@2.2.0: resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} engines: {node: '>=6'} - p-wait-for@5.0.2: - resolution: {integrity: sha512-lwx6u1CotQYPVju77R+D0vFomni/AqRfqLmqQ8hekklqZ6gAY9rONh7lBQ0uxWMkC2AuX9b2DVAl8To0NyP1JA==} - engines: {node: '>=12'} - package-json-from-dist@1.0.1: resolution: {integrity: sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==} @@ -6321,22 +4811,6 @@ packages: parse-entities@4.0.2: resolution: {integrity: sha512-GG2AQYWoLgL877gQIKeRPGO1xF9+eG1ujIb5soS5gPvLQ1y2o8FL90w2QWNdf9I361Mpp7726c+lj3U0qK1uGw==} - parse-gitignore@2.0.0: - resolution: {integrity: sha512-RmVuCHWsfu0QPNW+mraxh/xjQVw/lhUCUru8Zni3Ctq3AoMhpDTq0OVdKS6iesd6Kqb7viCV3isAL43dciOSog==} - engines: {node: '>=14'} - - parse-imports@2.2.1: - resolution: {integrity: sha512-OL/zLggRp8mFhKL0rNORUTR4yBYujK/uU+xZL+/0Rgm2QE4nLO9v8PzEweSJEbMGKmDRjJE4R3IMJlL2di4JeQ==} - engines: {node: '>= 18'} - - parse-json@8.3.0: - resolution: {integrity: sha512-ybiGyvspI+fAoRQbIPRddCcSTV9/LsJbf0e/S85VLowVGzRmokfneg2kwVW/KU5rOXrPSbF1qAKPMgNTqqROQQ==} - engines: {node: '>=18'} - - parse-ms@2.1.0: - resolution: {integrity: sha512-kHt7kzLoS9VBZfUsiKjv43mr91ea+U05EyKkEtqp7vNbHxmaVuEqN7XxeEVnGrMtYOAxGrDElSi96K7EgO1zCA==} - engines: {node: '>=6'} - parse-numeric-range@1.3.0: resolution: {integrity: sha512-twN+njEipszzlMJd4ONUYgSfZPDxgHhT9Ahed5uTigpQn90FggW4SA/AIPq/6a149fTbE9qBEcSwE3FAEp6wQQ==} @@ -6356,28 +4830,14 @@ packages: resolution: {integrity: sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==} engines: {node: '>= 0.8'} - path-browserify@1.0.1: - resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} - path-exists@4.0.0: resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} engines: {node: '>=8'} - path-exists@5.0.0: - resolution: {integrity: sha512-RjhtfwJOxzcFmNOi6ltcbcu4Iu+FL3zEj83dk4kAS+fVpTxXLO1b38RvJgT/0QwvV/L3aY9TAnyv0EOqW4GoMQ==} - engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} - path-key@3.1.1: resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} engines: {node: '>=8'} - path-key@4.0.0: - resolution: {integrity: sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==} - engines: {node: '>=12'} - - path-parse@1.0.7: - resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==} - path-scurry@1.11.1: resolution: {integrity: sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==} engines: {node: '>=16 || 14 >=14.18'} @@ -6399,13 +4859,6 @@ packages: resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} engines: {node: '>=8'} - path-type@6.0.0: - resolution: {integrity: sha512-Vj7sf++t5pBD637NSfkxpHSMfWaeig5+DKWLhcqIYx6mWQz5hdJTGDVMQiJcw1ZYkhs7AazKDGpRVji1LJCZUQ==} - engines: {node: '>=18'} - - pathe@1.1.2: - resolution: {integrity: sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==} - pathe@2.0.3: resolution: {integrity: sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==} @@ -6416,15 +4869,9 @@ packages: resolution: {integrity: sha512-//nshmD55c46FuFw26xV/xFAaB5HF9Xdap7HJBBnrKdAd6/GxDBaNA1870O79+9ueg61cZLSVc+OaFlfmObYVQ==} engines: {node: '>= 14.16'} - pend@1.2.0: - resolution: {integrity: sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==} - periscopic@3.1.0: resolution: {integrity: sha512-vKiQ8RRtkl9P+r/+oefh25C3fhybptkHKCZSPlcXiJux2tJF55GnEj3BVn4A5gKfq9NWWXXrxkHBwVPUfH0opw==} - picocolors@1.0.0: - resolution: {integrity: sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==} - picocolors@1.1.1: resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} @@ -6436,9 +4883,6 @@ packages: resolution: {integrity: sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==} engines: {node: '>=12'} - picoquery@2.5.0: - resolution: {integrity: sha512-j1kgOFxtaCyoFCkpoYG2Oj3OdGakadO7HZ7o5CqyRazlmBekKhbDoUnNnXASE07xSY4nDImWZkrZv7toSxMi/g==} - pify@4.0.1: resolution: {integrity: sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==} engines: {node: '>=6'} @@ -6457,9 +4901,6 @@ packages: resolution: {integrity: sha512-o8mkY4E/+LNUf6LzX96ht6k6CEDi65k9G2rjMtBe9Oo+VPKSvl+0GKHuH/AlG+GA5LPG/i5hrekkxUc3s2HU+Q==} hasBin: true - pkg-types@1.3.1: - resolution: {integrity: sha512-/Jm5M4RvtBFVkKWRu2BLUTNP8/M2a+UwuAX+ae4770q1qVGtfjG+WTCupoZixokjmHiry8uI+dlY8KXYV5HVVQ==} - pkg-types@2.3.0: resolution: {integrity: sha512-SIqCzDRg0s9npO5XQ3tNZioRY1uK06lA41ynBC1YmFTmnY6FjUjVt6s4LoADmwoig1qqD0oK8h1p/8mlMx8Oig==} @@ -6491,21 +4932,10 @@ packages: resolution: {integrity: sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==} engines: {node: '>= 0.4'} - postcss-values-parser@6.0.2: - resolution: {integrity: sha512-YLJpK0N1brcNJrs9WatuJFtHaV9q5aAOj+S4DI5S7jgHlRfm0PIbDCAFRYMQD5SHq7Fy6xsDhyutgS0QOAs0qw==} - engines: {node: '>=10'} - peerDependencies: - postcss: ^8.2.9 - postcss@8.5.6: resolution: {integrity: sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg==} engines: {node: ^10 || ^12 || >=14} - precinct@12.2.0: - resolution: {integrity: sha512-NFBMuwIfaJ4SocE9YXPU/n4AcNSoFMVFjP72nvl3cx69j/ke61/hPOWFREVxLkFhhEGnA8ZuVfTqJBa+PK3b5w==} - engines: {node: '>=18'} - hasBin: true - prettier@2.8.8: resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} engines: {node: '>=10.13.0'} @@ -6520,23 +4950,12 @@ packages: resolution: {integrity: sha512-Qb1gy5OrP5+zDf2Bvnzdl3jsTf1qXVMazbvCoKhtKqVs4/YK4ozX4gKQJJVyNe+cajNPn0KoC0MC3FUmaHWEmQ==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} - pretty-ms@7.0.1: - resolution: {integrity: sha512-973driJZvxiGOQ5ONsFhOF/DtzPMOMtgC11kCpUrPGMTgqp2q/1gwzCquocrN33is0VZ5GFHXZYMM9l6h67v2Q==} - engines: {node: '>=10'} - - process-nextick-args@2.0.1: - resolution: {integrity: sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==} - process-warning@4.0.1: resolution: {integrity: sha512-3c2LzQ3rY9d0hc1emcsHhfT9Jwz0cChib/QN89oME2R451w5fy3f0afAhERFZAwrbDU43wk12d0ORBpDVME50Q==} process-warning@5.0.0: resolution: {integrity: sha512-a39t9ApHNx2L4+HBnQKqxxHNs1r7KF+Intd8Q/g1bUh6q0WIp9voPXJ/x0j+ZL45KF1pJd9+q2jLIRMfvEshkA==} - process@0.11.10: - resolution: {integrity: sha512-cdGef/drWFoydD1JsMzuFf8100nZl+GT+yacc2bEced5f9Rjk4z+WtFUTBu9PhOi9j/jfmBPu0mMEY4wIdAF8A==} - engines: {node: '>= 0.6.0'} - property-information@7.1.0: resolution: {integrity: sha512-TwEZ+X+yCJmYfL7TPUOcvBZ4QfoT5YenQiJuX//0th53DE6w0xxLEtfK3iyryQFddXuvkIk51EEgrJQ0WJkOmQ==} @@ -6544,9 +4963,6 @@ packages: resolution: {integrity: sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==} engines: {node: '>= 0.10'} - pump@3.0.3: - resolution: {integrity: sha512-todwxLMY7/heScKmntwQG8CXVkWUOdYxIvY2s0VWAAMh/nd8SoYiRaKjlr7+iCs984f2P8zvrfWcDDYVb73NfA==} - punycode@2.3.1: resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} engines: {node: '>=6'} @@ -6567,9 +4983,6 @@ packages: quick-format-unescaped@4.0.4: resolution: {integrity: sha512-tYC1Q1hgyRuHgloV/YXs2w15unPVh8qfu/qCTfhTYamaw7fyhumKa2yGpdSo87vY32rIclj+4fWYQXUMs9EHvg==} - quote-unquote@1.0.0: - resolution: {integrity: sha512-twwRO/ilhlG/FIgYeKGFqyHhoEhqgnKVkcmqMKi2r524gz3ZbDTcyFt38E9xjJI2vT+KbRNHVbnJ/e0I25Azwg==} - radix3@1.1.2: resolution: {integrity: sha512-b484I/7b8rDEdSDKckSSBA8knMpcdsXudlE/LNL639wFoHKwLbEkQFZHWEYwDC0wa0FKUcCY+GAF73Z7wxNVFA==} @@ -6597,40 +5010,14 @@ packages: resolution: {integrity: sha512-Ku/hhYbVjOQnXDZFv2+RibmLFGwFdeeKHFcOTlrt7xplBnya5OGn/hIRDsqDiSUcfORsDC7MPxwork8jBwsIWA==} engines: {node: '>=0.10.0'} - read-package-up@11.0.0: - resolution: {integrity: sha512-MbgfoNPANMdb4oRBNg5eqLbB2t2r+o5Ua1pNt8BqGp4I0FJZhuVSOj3PaBPni4azWuSzEdNn2evevzVmEk1ohQ==} - engines: {node: '>=18'} - - read-pkg@9.0.1: - resolution: {integrity: sha512-9viLL4/n1BJUCT1NXVTdS1jtm80yDEgR5T4yCelII49Mbj0v1rZdKqj7zCiYdbB0CuCgdrvHcNogAKTFPBocFA==} - engines: {node: '>=18'} - read-yaml-file@1.1.0: resolution: {integrity: sha512-VIMnQi/Z4HT2Fxuwg5KrY174U1VdUIASQVWXXyqtNRtxSr9IYkn1rsI6Tb6HsrHCmB7gVpNwX6JxPTHcH6IoTA==} engines: {node: '>=6'} - readable-stream@2.3.8: - resolution: {integrity: sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==} - - readable-stream@3.6.2: - resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} - engines: {node: '>= 6'} - - readable-stream@4.7.0: - resolution: {integrity: sha512-oIGGmcpTLwPga8Bn6/Z75SVaH1z5dUut2ibSyAMVhmUggWpmDn2dapB0n7f8nwaSiRtepAsfJyfXIO5DCVAODg==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - - readdir-glob@1.1.3: - resolution: {integrity: sha512-v05I2k7xN8zXvPD9N+z/uhXPaj0sUFCe2rcWZIpBsqxfP7xXFQ0tipAd/wjj1YxWyWtUS5IDJpOG82JKt2EAVA==} - readdirp@3.6.0: resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} engines: {node: '>=8.10.0'} - readdirp@4.1.2: - resolution: {integrity: sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==} - engines: {node: '>= 14.18.0'} - real-require@0.2.0: resolution: {integrity: sha512-57frrGM/OCTLqLOAh0mhVA9VBMHd+9U7Zb2THMGdBUoZVOtGbJzjxsYGDJ3A9AYYCP4hn6y1TVbaOfzWtm5GFg==} engines: {node: '>= 12.13.0'} @@ -6675,24 +5062,10 @@ packages: remark-stringify@11.0.0: resolution: {integrity: sha512-1OSmLd3awB/t8qdoEOMazZkNsfVTeY4fTsgzcQFdXNq8ToTN4ZGwrMnlda4K6smTFKD+GRV6O48i6Z4iKgPPpw==} - remove-trailing-separator@1.1.0: - resolution: {integrity: sha512-/hS+Y0u3aOfIETiaiirUFwDBDzmXPvO+jAfKTitUngIPzdKc6Z0LoFjM/CK5PL4C+eKwHohlHAb6H0VFfmmUsw==} - - require-directory@2.1.1: - resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} - engines: {node: '>=0.10.0'} - require-from-string@2.0.2: resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==} engines: {node: '>=0.10.0'} - require-in-the-middle@7.5.2: - resolution: {integrity: sha512-gAZ+kLqBdHarXB64XpAe2VCjB7rIRv+mU8tfRWziHRJ5umKsIHN2tLLv6EtMw7WCdP19S0ERVMldNvxYCHnhSQ==} - engines: {node: '>=8.6.0'} - - require-package-name@2.0.1: - resolution: {integrity: sha512-uuoJ1hU/k6M0779t3VMVIYpb2VMJk05cehCaABFhXaibcbvfgR8wKiozLjVFSzJPmQMRqIcO0HMyTFqfV09V6Q==} - resolve-from@5.0.0: resolution: {integrity: sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==} engines: {node: '>=8'} @@ -6700,23 +5073,10 @@ packages: resolve-pkg-maps@1.0.0: resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} - resolve@1.22.11: - resolution: {integrity: sha512-RfqAvLnMl313r7c9oclB1HhUEAezcpLjz95wFH4LVuhk9JF/r22qmVP9AMmOU4vMX7Q8pN8jwNg/CSpdFnMjTQ==} - engines: {node: '>= 0.4'} - hasBin: true - - resolve@2.0.0-next.5: - resolution: {integrity: sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==} - hasBin: true - ret@0.5.0: resolution: {integrity: sha512-I1XxrZSQ+oErkRR4jYbAyEEu2I0avBvvMM5JN+6EBprOGRCs63ENqZ3vjavq8fBw2+62G5LF5XelKwuJpcvcxw==} engines: {node: '>=10'} - retry@0.13.1: - resolution: {integrity: sha512-XQBQ3I8W1Cge0Seh+6gjj03LbmRFWuoszgK9ooCpwYIrhhoO80pfq4cUkU5DkknwfOfFteRwlZ56PYOGYyFWdg==} - engines: {node: '>= 4'} - reusify@1.1.0: resolution: {integrity: sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==} engines: {iojs: '>=1.0.0', node: '>=0.10.0'} @@ -6758,8 +5118,8 @@ packages: engines: {node: '>=18.0.0', npm: '>=8.0.0'} hasBin: true - rou3@0.7.10: - resolution: {integrity: sha512-aoFj6f7MJZ5muJ+Of79nrhs9N3oLGqi2VEMe94Zbkjb6Wupha46EuoYgpWSOZlXww3bbd8ojgXTAA2mzimX5Ww==} + rou3@0.7.12: + resolution: {integrity: sha512-iFE4hLDuloSWcD7mjdCDhx2bKcIsYbtOTpfH5MHHLSKMOUyjqQXTeZVa289uuwEGEKFoE/BAPbhaU4B774nceg==} router@2.2.0: resolution: {integrity: sha512-nLTrUKm2UyiL7rlhapu/Zl45FwNgkZGaCpZbIHajDYgwlJCOzLSk+cIPAnsEqV955GjILJnKbdQC1nVPz+gAYQ==} @@ -6772,9 +5132,6 @@ packages: resolution: {integrity: sha512-AURm5f0jYEOydBj7VQlVvDrjeFgthDdEF5H1dP+6mNpoXOMo1quQqJ4wvJDyRZ9+pO3kGWoOdmV08cSv2aJV6Q==} engines: {node: '>=0.4'} - safe-buffer@5.1.2: - resolution: {integrity: sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==} - safe-buffer@5.2.1: resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} @@ -6796,9 +5153,6 @@ packages: safer-buffer@2.1.2: resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} - sax@1.4.3: - resolution: {integrity: sha512-yqYn1JhPczigF94DMS+shiDMjDowYO6y9+wB/4WgO0Y19jWYk0lQ4tuG5KI7kj4FTp1wxPj5IFfcrz/s1c3jjQ==} - saxes@6.0.0: resolution: {integrity: sha512-xAg7SOnEhrm5zI3puOOKyy1OMcMlIJZYNJY7xLBwSze0UjhPLnWfj2GF2EpT0jmzaJKIWKHLsaSSajf35bcYnA==} engines: {node: '>=v12.22.7'} @@ -6874,10 +5228,6 @@ packages: resolution: {integrity: sha512-haPVm1EkS9pgvHrQ/F3Xy+hgcuMV0Wm9vfIBSiwZ05k+xgb0PkBQpGsAA/oWdDobNaZTH5ppvHtzCFbnSEwHVw==} engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - sharp@0.34.5: - resolution: {integrity: sha512-Ou9I5Ft9WNcCbXrU9cMgPBcCK8LiwLqcbywW3t4oDV37n1pzpuNLsYiAV8eODnjbtQlSDwZ2cUEeQz4E54Hltg==} - engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0} - shebang-command@2.0.0: resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} engines: {node: '>=8'} @@ -6912,10 +5262,6 @@ packages: siginfo@2.0.0: resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==} - signal-exit@4.0.2: - resolution: {integrity: sha512-MY2/qGx4enyjprQnFaZsHib3Yadh3IXyV2C321GY0pjGfVBu4un0uDJkwgdxqO+Rdx8JMT8IfJIRwbYVz3Ob3Q==} - engines: {node: '>=14'} - signal-exit@4.1.0: resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} engines: {node: '>=14'} @@ -6931,9 +5277,6 @@ packages: resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} engines: {node: '>=8'} - slashes@3.0.12: - resolution: {integrity: sha512-Q9VME8WyGkc7pJf6QEkj3wE+2CnvZMI+XJhwdTPR8Z/kWQRXi7boAWLDibRPyHRTUTPx5FaU7MsyrjI3yLB4HA==} - solid-js@1.9.10: resolution: {integrity: sha512-Coz956cos/EPDlhs6+jsdTxKuJDPT7B5SVIWgABwROyxjY7Xbr8wkzD68Et+NxnV7DLJ3nJdAC2r9InuV/4Jew==} @@ -6961,18 +5304,6 @@ packages: spawndamnit@3.0.1: resolution: {integrity: sha512-MmnduQUuHCoFckZoWnXsTg7JaiLBJrKFj9UI2MbRPGaJeVpsLcVBu6P/IGZovziM/YBsellCmsprgNA+w0CzVg==} - spdx-correct@3.2.0: - resolution: {integrity: sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==} - - spdx-exceptions@2.5.0: - resolution: {integrity: sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==} - - spdx-expression-parse@3.0.1: - resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==} - - spdx-license-ids@3.0.22: - resolution: {integrity: sha512-4PRT4nh1EImPbt2jASOKHX7PB7I+e4IWNLvkKFDxNhJlfjbYlleYQh285Z/3mPTHSAK/AvdMmw5BNNuYH8ShgQ==} - split2@4.2.0: resolution: {integrity: sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg==} engines: {node: '>= 10.x'} @@ -6990,9 +5321,6 @@ packages: engines: {node: '>=20.16.0'} hasBin: true - stack-trace@0.0.10: - resolution: {integrity: sha512-KGzahc7puUKkzyMt+IqAep+TVNbKP+k2Lmwhub39m1AsTSkaDutx56aDCo+HLDzf/D26BIHTJWNiTG1KAJiQCg==} - stackback@0.0.2: resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==} @@ -7018,9 +5346,6 @@ packages: resolution: {integrity: sha512-KXDYZ9dszj6bzvnEMRYvxgeTHU74QBFL54XKtP3nyMuJ81CFYtABZ3bAzL2EdFUaEwJOBOgENyFj3R7oTzDyyw==} engines: {node: '>=4', npm: '>=6'} - streamx@2.23.0: - resolution: {integrity: sha512-kn+e44esVfn2Fa/O0CPFcex27fjIL6MkVae0Mm6q+E6f0hWv578YCERbv+4m02cjxvDsPKLnmxral/rR6lBMAg==} - string-width@4.2.3: resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} engines: {node: '>=8'} @@ -7045,12 +5370,6 @@ packages: resolution: {integrity: sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==} engines: {node: '>= 0.4'} - string_decoder@1.1.1: - resolution: {integrity: sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==} - - string_decoder@1.3.0: - resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} - stringify-entities@4.0.4: resolution: {integrity: sha512-IwfBptatlO+QCJUo19AqvrPNqlVMpW9YEL2LIVY+Rpv2qsjCGxaDLNRgeGsQWJhfItebuJhsGSLjaBbNSQ+ieg==} @@ -7066,10 +5385,6 @@ packages: resolution: {integrity: sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==} engines: {node: '>=4'} - strip-final-newline@3.0.0: - resolution: {integrity: sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==} - engines: {node: '>=12'} - strip-literal@3.1.0: resolution: {integrity: sha512-8r3mkIM/2+PpjHoOtiAW8Rg3jJLHaV7xPwG+YRGrv6FP0wwk/toTpATxWYOW0BKdWwl82VT2tFYi5DlROa0Mxg==} @@ -7087,26 +5402,9 @@ packages: resolution: {integrity: sha512-SS+jx45GF1QjgEXQx4NJZV9ImqmO2NPz5FNsIHrsDjh2YsHnawpan7SNQ1o8NuhrbHZy9AZhIoCUiCeaW/C80g==} engines: {node: '>=18'} - supports-color@7.2.0: - resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} - engines: {node: '>=8'} - - supports-preserve-symlinks-flag@1.0.0: - resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} - engines: {node: '>= 0.4'} - - svgo@4.0.0: - resolution: {integrity: sha512-VvrHQ+9uniE+Mvx3+C9IEe/lWasXCU0nXMY2kZeLrHNICuRiC8uMPyM14UEaMOFA5mhyQqEkB02VoQ16n3DLaw==} - engines: {node: '>=16'} - hasBin: true - symbol-tree@3.2.4: resolution: {integrity: sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==} - system-architecture@0.1.0: - resolution: {integrity: sha512-ulAk51I9UVUyJgxlv9M6lFot2WP3e7t8Kz9+IS6D4rVba1tR9kON+Ey69f+1R4Q8cd45Lod6a4IcJIxnzGc/zA==} - engines: {node: '>=18'} - tailwindcss@4.1.17: resolution: {integrity: sha512-j9Ee2YjuQqYT9bbRTfTZht9W/ytp5H+jJpZKiYdP/bpnXARAuELt9ofP0lPnmHjbga7SNQIxdTAXCmtKVYjN+Q==} @@ -7114,9 +5412,6 @@ packages: resolution: {integrity: sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==} engines: {node: '>=6'} - tar-stream@3.1.7: - resolution: {integrity: sha512-qJj60CXt7IU1Ffyc3NJMjh6EkuCFej46zUqJ4J7pqYlThyd9bO0XBTmcOIhSzZJVWfsLks0+nle/j538YAW9RQ==} - tar@7.5.1: resolution: {integrity: sha512-nlGpxf+hv0v7GkWBK2V9spgactGOp0qvfWRxUMjqHyzrt3SgwE48DIv/FhqPHJYLHpgW1opq3nERbz5Anq7n1g==} engines: {node: '>=18'} @@ -7126,19 +5421,9 @@ packages: resolution: {integrity: sha512-wK0Ri4fOGjv/XPy8SBHZChl8CM7uMc5VML7SqiQ0zG7+J5Vr+RMQDoHa2CNT6KHUnTGIXH34UDMkPzAUyapBZg==} engines: {node: '>=8'} - text-decoder@1.2.3: - resolution: {integrity: sha512-3/o9z3X0X0fTupwsYvR03pJ/DjWuqqrfwBgTQzdWDiQSm9KitAyz/9WqsT2JQW7KV2m+bC2ol/zqpW37NHxLaA==} - - text-hex@1.0.0: - resolution: {integrity: sha512-uuVGNWzgJ4yhRaNSiubPY7OjISw4sw4E5Uv0wbjp+OzcbmVU/rsT8ujgcXJhn9ypzsgr5vlzpPqP+MBBKcGvbg==} - thread-stream@3.1.0: resolution: {integrity: sha512-OqyPZ9u96VohAyMfJykzmivOrY2wfMSf3C5TtFJVgN+Hm6aj+voFhlK+kZEIv2FBh1X6Xp3DlnCOfEQ3B2J86A==} - time-span@4.0.0: - resolution: {integrity: sha512-MyqZCTGLDZ77u4k+jqg4UlrzPTPZ49NDlaekU6uuFaJLzPIN1woaRXCbGeqOfxwc3Y37ZROGAJ614Rdv7Olt+g==} - engines: {node: '>=10'} - tiny-invariant@1.3.3: resolution: {integrity: sha512-+FbBPE1o9QAYvviau/qC5SE3caw21q3xkvWKBtja5vgqOWIHHJ3ioaq1VPfn/Szqctz2bU/oYeKd9/z5BL+PVg==} @@ -7178,13 +5463,6 @@ packages: resolution: {integrity: sha512-Y1KQBgDd/NUc+LfOtKS6mNsC9CCaH+m2P1RoIZy7RAPo3C3/t8X45+zgut31cRZtZ3xKPjfn3TkGTrctC2TQIQ==} hasBin: true - tmp-promise@3.0.3: - resolution: {integrity: sha512-RwM7MoPojPxsOBYnyd2hy0bxtIlVrihNs9pj5SUvY8Zz1sQcQG2tG1hSr8PDxfgEB8RNKDhqbIlroIarSNDNsQ==} - - tmp@0.2.5: - resolution: {integrity: sha512-voyz6MApa1rQGUxT3E+BK7/ROe8itEx7vD8/HEvt4xwXucvQ5G5oeEiHkmHZJuBO21RpOf+YYm9MOivj709jow==} - engines: {node: '>=14.14'} - to-regex-range@5.0.1: resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} engines: {node: '>=8.0'} @@ -7201,12 +5479,6 @@ packages: resolution: {integrity: sha512-kh9LVIWH5CnL63Ipf0jhlBIy0UsrMj/NJDfpsy1SqOXlLKEVyXXYrnFxFT1yOOYVGBSApeVnjPw/sBz5BfEjAQ==} engines: {node: '>=14.16'} - toml@3.0.0: - resolution: {integrity: sha512-y/mWCZinnvxjTKYhJ+pYxwD0mRLVvOtdS2Awbgxln6iEnt4rk0yBxeSBHkGJcPucRiG0e55mwWp+g/05rsrd6w==} - - tomlify-j0.4@3.0.0: - resolution: {integrity: sha512-2Ulkc8T7mXJ2l0W476YC/A209PR38Nw8PuaCNtk9uI3t1zzFdGQeWYGQvmj2PZkVvRC/Yoi4xQKMRnWc/N29tQ==} - totalist@3.0.1: resolution: {integrity: sha512-sf4i37nQ2LBx4m3wB74y+ubopq6W/dIzXg0FDGjsYnZHVa1Da8FH853wlL2gtUhg+xJXjfk3kUZS3BRoQeoQBQ==} engines: {node: '>=6'} @@ -7229,43 +5501,13 @@ packages: trim-lines@3.0.1: resolution: {integrity: sha512-kRj8B+YHZCc9kQYdWfJB2/oUl9rA99qbowYYBtr4ui4mZyAQ2JpvVBd/6U2YloATfqBhBTSMhTpgBHtU0Mf3Rg==} - triple-beam@1.4.1: - resolution: {integrity: sha512-aZbgViZrg1QNcG+LULa7nhZpJTZSLm/mXnHXnbAbjmN5aSa0y7V+wvv6+4WaBtpISJzThKy+PIPxc1Nq1EJ9mg==} - engines: {node: '>= 14.0.0'} - trough@2.2.0: resolution: {integrity: sha512-tmMpK00BjZiUyVyvrBK7knerNgmgvcV/KLVyuma/SC+TQN167GrMRciANTz09+k3zW8L8t60jWO1GpfkZdjTaw==} - ts-api-utils@2.1.0: - resolution: {integrity: sha512-CUgTZL1irw8u29bzrOD/nH85jqyc74D6SshFgujOIA7osm2Rz7dYH77agkx7H4FBNxDq7Cjf+IjaX/8zwFW+ZQ==} - engines: {node: '>=18.12'} - peerDependencies: - typescript: '>=4.8.4' - ts-deepmerge@7.0.3: resolution: {integrity: sha512-Du/ZW2RfwV/D4cmA5rXafYjBQVuvu4qGiEEla4EmEHVHgRdx68Gftx7i66jn2bzHPwSVZY36Ae6OuDn9el4ZKA==} engines: {node: '>=14.13.1'} - ts-morph@12.0.0: - resolution: {integrity: sha512-VHC8XgU2fFW7yO1f/b3mxKDje1vmyzFXHWzOYmKEkCEwcLjDtbdLgBQviqj4ZwP4MJkQtRo6Ha2I29lq/B+VxA==} - - ts-node@10.9.1: - resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==} - hasBin: true - peerDependencies: - '@swc/core': '>=1.2.50' - '@swc/wasm': '>=1.2.50' - '@types/node': '*' - typescript: '>=2.7' - peerDependenciesMeta: - '@swc/core': - optional: true - '@swc/wasm': - optional: true - - ts-toolbelt@6.15.5: - resolution: {integrity: sha512-FZIXf1ksVyLcfr7M317jbB67XFJhOO1YqdTcuGaq9q5jLUoTikukZ+98TPjKiP2jC5CgmYdWWYs0s2nLSU0/1A==} - tsconfck@3.1.6: resolution: {integrity: sha512-ks6Vjr/jEw0P1gmOVwutM3B7fWxoWBL2KRDb1JfqGVawBmO5UsvmWOQFGHBPl5yxYz4eERr19E6L7NMv+Fej4w==} engines: {node: ^18 || >=20} @@ -7313,10 +5555,6 @@ packages: resolution: {integrity: sha512-Acylog8/luQ8L7il+geoSxhEkazvkslg7PSNKOX59mbB9cOveP5aq9h74Y7YU8yDpJwetzQQrfIwtf4Wp4LKcw==} engines: {node: '>=4'} - type-fest@4.41.0: - resolution: {integrity: sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==} - engines: {node: '>=16'} - type-is@2.0.1: resolution: {integrity: sha512-OZs6gsjF4vMp32qrCbiVSkrFmXtG/AZhY3t0iAMrMBiAZyV9oALtXO8hsrHbMXF9x6L3grlFuwW2oAz7cav+Gw==} engines: {node: '>= 0.6'} @@ -7337,11 +5575,6 @@ packages: resolution: {integrity: sha512-3KS2b+kL7fsuk/eJZ7EQdnEmQoaho/r6KUef7hxvltNA5DR8NAUM+8wJMbJyZ4G9/7i3v5zPBIMN5aybAh2/Jg==} engines: {node: '>= 0.4'} - typescript@4.9.5: - resolution: {integrity: sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==} - engines: {node: '>=4.2.0'} - hasBin: true - typescript@5.9.3: resolution: {integrity: sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==} engines: {node: '>=14.17'} @@ -7354,10 +5587,6 @@ packages: resolution: {integrity: sha512-rvKSBiC5zqCCiDZ9kAOszZcDvdAHwwIKJG33Ykj43OKcWsnmcBRL09YTU4nOeHZ8Y2a7l1MgTd08SBe9A8Qj6A==} engines: {node: '>=18'} - ulid@3.0.2: - resolution: {integrity: sha512-yu26mwteFYzBAot7KVMqFGCVpsF6g8wXfJzQUHvu1no3+rRRSFcSV2nKeYvNPLD2J4b08jYBDhHUjeH0ygIl9w==} - hasBin: true - unbox-primitive@1.1.0: resolution: {integrity: sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==} engines: {node: '>= 0.4'} @@ -7371,10 +5600,6 @@ packages: undici-types@6.21.0: resolution: {integrity: sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==} - undici@5.28.4: - resolution: {integrity: sha512-72RFADWFqKmUb2hmmvNODKL3p9hcB6Gt2DOQMis1SEBaV6a4MH8soBvzg+95CYhCKPFedut2JY9bMfrDl9D23g==} - engines: {node: '>=14.0'} - undici@7.14.0: resolution: {integrity: sha512-Vqs8HTzjpQXZeXdpsfChQTlafcMQaaIwnGwLam1wudSSjlJeQ3bw1j+TLPePgrCnCpUXx7Ba5Pdpf5OBih62NQ==} engines: {node: '>=20.18.1'} @@ -7382,10 +5607,6 @@ packages: unenv@2.0.0-rc.24: resolution: {integrity: sha512-i7qRCmY42zmCwnYlh9H2SvLEypEFGye5iRmEMKjcGi7zk9UquigRjFtTLz0TYqr0ZGLZhaMHl/foy1bZR+Cwlw==} - unicorn-magic@0.1.0: - resolution: {integrity: sha512-lRfVq8fE8gz6QMBuDM6a+LO3IAzTi05H6gCVaUpir2E1Rwpo4ZUog45KpNXKC/Mn3Yb9UDuHumeFTo9iV/D9FQ==} - engines: {node: '>=18'} - unified@11.0.5: resolution: {integrity: sha512-xKvGhPWw3k84Qjh8bI3ZeJjqnyadK+GEFtazSfZv/rKeTkTjOJho6mFqh2SM96iIcZokxiOpg78GazTSg8+KHA==} @@ -7411,10 +5632,6 @@ packages: resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} engines: {node: '>= 4.0.0'} - unixify@1.0.0: - resolution: {integrity: sha512-6bc58dPYhCMHHuwxldQxO3RRNZ4eCogZ/st++0+fcC1nr0jiGUtAdBJ2qzmLQWSxbtz42pWt4QQMiZ9HvZf5cg==} - engines: {node: '>=0.10.0'} - unpipe@1.0.0: resolution: {integrity: sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==} engines: {node: '>= 0.8'} @@ -7433,115 +5650,19 @@ packages: synckit: optional: true - unstorage@1.17.3: - resolution: {integrity: sha512-i+JYyy0DoKmQ3FximTHbGadmIYb8JEpq7lxUjnjeB702bCPum0vzo6oy5Mfu0lpqISw7hCyMW2yj4nWC8bqJ3Q==} - peerDependencies: - '@azure/app-configuration': ^1.8.0 - '@azure/cosmos': ^4.2.0 - '@azure/data-tables': ^13.3.0 - '@azure/identity': ^4.6.0 - '@azure/keyvault-secrets': ^4.9.0 - '@azure/storage-blob': ^12.26.0 - '@capacitor/preferences': ^6.0.3 || ^7.0.0 - '@deno/kv': '>=0.9.0' - '@netlify/blobs': ^6.5.0 || ^7.0.0 || ^8.1.0 || ^9.0.0 || ^10.0.0 - '@planetscale/database': ^1.19.0 - '@upstash/redis': ^1.34.3 - '@vercel/blob': '>=0.27.1' - '@vercel/functions': ^2.2.12 || ^3.0.0 - '@vercel/kv': ^1.0.1 - aws4fetch: ^1.0.20 - db0: '>=0.2.1' - idb-keyval: ^6.2.1 - ioredis: ^5.4.2 - uploadthing: ^7.4.4 - peerDependenciesMeta: - '@azure/app-configuration': - optional: true - '@azure/cosmos': - optional: true - '@azure/data-tables': - optional: true - '@azure/identity': - optional: true - '@azure/keyvault-secrets': - optional: true - '@azure/storage-blob': - optional: true - '@capacitor/preferences': - optional: true - '@deno/kv': - optional: true - '@netlify/blobs': - optional: true - '@planetscale/database': - optional: true - '@upstash/redis': - optional: true - '@vercel/blob': - optional: true - '@vercel/functions': - optional: true - '@vercel/kv': - optional: true - aws4fetch: - optional: true - db0: - optional: true - idb-keyval: - optional: true - ioredis: - optional: true - uploadthing: - optional: true - - untun@0.1.3: - resolution: {integrity: sha512-4luGP9LMYszMRZwsvyUd9MrxgEGZdZuZgpVQHEEX0lCYFESasVRvZd0EYpCkOIbJKHMuv0LskpXc/8Un+MJzEQ==} - hasBin: true - update-browserslist-db@1.1.3: resolution: {integrity: sha512-UxhIZQ+QInVdunkDAaiazvvT/+fXL5Osr0JZlJulepYu6Jd7qJtDZjlur0emRlT71EN3ScPoE7gvsuIKKNavKw==} hasBin: true peerDependencies: browserslist: '>= 4.21.0' - uqr@0.1.2: - resolution: {integrity: sha512-MJu7ypHq6QasgF5YRTjqscSzQp/W11zoUk6kvmlH+fmWEs63Y0Eib13hYFwAzagRJcVY8WVnlV+eBDUGMJ5IbA==} - uri-js@4.4.1: - resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} - - urlpattern-polyfill@10.1.0: - resolution: {integrity: sha512-IGjKp/o0NL3Bso1PymYURCJxMPNAf/ILOpendP9f5B6e1rTJgdgiOvgfoT8VxCAdY+Wisb9uhGaJJf3yZ2V9nw==} - - urlpattern-polyfill@8.0.2: - resolution: {integrity: sha512-Qp95D4TPJl1kC9SKigDcqgyM2VDVO4RiJc2d4qe5GrYm+zbIQCWWKAFaJNQ4BhdFeDGwBmAxqJBwWSJDb9T3BQ==} - - use-sync-external-store@1.6.0: - resolution: {integrity: sha512-Pp6GSwGP/NrPIrxVFAIkOQeyw8lFenOHijQWkUTrDvrF4ALqylP2C/KCkeS9dpUM3KvYRQhna5vt7IL95+ZQ9w==} - peerDependencies: - react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 - - util-deprecate@1.0.2: - resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} - - uuid@11.1.0: - resolution: {integrity: sha512-0/A9rDy9P7cJ+8w1c9WD9V//9Wj15Ce2MPz8Ri6032usz+NfePxx5AcN3bN+r6ZL6jEo066/yNYB3tn4pQEx+A==} - hasBin: true - - uuid@13.0.0: - resolution: {integrity: sha512-XQegIaBTVUjSHliKqcnFqYypAd4S+WCYt5NIeRs6w/UAry7z8Y9j5ZwRRL4kzq9U3sD6v+85er9FvkEaBpji2w==} - hasBin: true - - v8-compile-cache-lib@3.0.1: - resolution: {integrity: sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==} - - validate-npm-package-license@3.0.4: - resolution: {integrity: sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==} + resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} - validate-npm-package-name@5.0.1: - resolution: {integrity: sha512-OljLrQ9SQdOUqTaQxqL5dEfZWrXExyyWsozYlAWFawPVNuD83igl7uJD2RTkNMbniIYgt8l81eCJGIdQF7avLQ==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} + use-sync-external-store@1.6.0: + resolution: {integrity: sha512-Pp6GSwGP/NrPIrxVFAIkOQeyw8lFenOHijQWkUTrDvrF4ALqylP2C/KCkeS9dpUM3KvYRQhna5vt7IL95+ZQ9w==} + peerDependencies: + react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 vary@1.1.2: resolution: {integrity: sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==} @@ -7670,10 +5791,6 @@ packages: web-namespaces@2.0.1: resolution: {integrity: sha512-bKr1DkiNa2krS7qxNtdrtHAmzuYGFQLiQ13TsorsdT6ULTkPLKuu5+GsFpDlg6JFjUTwX2DyhMPG2be8uPrqsQ==} - web-streams-polyfill@3.3.3: - resolution: {integrity: sha512-d2JWLCivmZYTSIoge9MsgFCZrt571BikcWGYkjC1khllbTeDlGqZ2D8vD8E/lJa8WGWbb7Plm8/XJYV7IJHZZw==} - engines: {node: '>= 8'} - web-vitals@5.1.0: resolution: {integrity: sha512-ArI3kx5jI0atlTtmV0fWU3fjpLmq/nD3Zr1iFFlJLaqa5wLBkUSzINwBPySCX/8jRyjlmy1Volw1kz1g9XE4Jg==} @@ -7729,14 +5846,6 @@ packages: engines: {node: '>=8'} hasBin: true - winston-transport@4.9.0: - resolution: {integrity: sha512-8drMJ4rkgaPo1Me4zD/3WLfI/zPdA9o2IipKODunnGDcuqbHwjsbB79ylv04LCGGzU0xQ6vTznOMpQGaLhhm6A==} - engines: {node: '>= 12.0.0'} - - winston@3.18.3: - resolution: {integrity: sha512-NoBZauFNNWENgsnC9YpgyYwOVrl2m58PpQ8lNHjV3kosGs7KJ7Npk9pCUE+WJlawVSe8mykWDKWFSVfs3QO9ww==} - engines: {node: '>= 12.0.0'} - workerd@1.20251217.0: resolution: {integrity: sha512-s3mHDSWwHTduyY8kpHOsl27ZJ4ziDBJlc18PfBvNMqNnhO7yBeemlxH7bo7yQyU1foJrIZ6IENHDDg0Z9N8zQA==} engines: {node: '>=16'} @@ -7764,10 +5873,6 @@ packages: wrappy@1.0.2: resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} - write-file-atomic@5.0.1: - resolution: {integrity: sha512-+QU2zd6OTD8XWIJCbffaiQeH9U73qIqafo1x6V1snCWYGJf6cVE0cDR4D8xRzcEnfI21IFrUPzPGtcPf8AC+Rw==} - engines: {node: ^14.17.0 || ^16.13.0 || >=18.0.0} - ws@8.18.0: resolution: {integrity: sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==} engines: {node: '>=10.0.0'} @@ -7803,15 +5908,6 @@ packages: xmlchars@2.2.0: resolution: {integrity: sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==} - xss@1.0.15: - resolution: {integrity: sha512-FVdlVVC67WOIPvfOwhoMETV72f6GbW7aOabBC3WxN/oUdoEMDyLz4OgRv5/gck2ZeNqEQu+Tb0kloovXOfpYVg==} - engines: {node: '>= 0.10.0'} - hasBin: true - - y18n@5.0.8: - resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} - engines: {node: '>=10'} - yallist@3.1.1: resolution: {integrity: sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==} @@ -7827,35 +5923,12 @@ packages: engines: {node: '>= 14.6'} hasBin: true - yargs-parser@21.1.1: - resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==} - engines: {node: '>=12'} - - yargs@17.7.2: - resolution: {integrity: sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==} - engines: {node: '>=12'} - - yauzl@2.10.0: - resolution: {integrity: sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==} - - yn@3.1.1: - resolution: {integrity: sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==} - engines: {node: '>=6'} - - yocto-queue@1.2.2: - resolution: {integrity: sha512-4LCcse/U2MHZ63HAJVE+v71o7yOdIe4cZ70Wpf8D/IyjDKYQLV5GD46B+hSTjJsvV5PztjvHoU580EftxjDZFQ==} - engines: {node: '>=12.20'} - youch-core@0.3.3: resolution: {integrity: sha512-ho7XuGjLaJ2hWHoK8yFnsUGy2Y5uDpqSTq1FkHLK4/oqKtyUU1AFbOOxY4IpC9f0fTLjwYbslUz0Po5BpD1wrA==} youch@4.1.0-beta.10: resolution: {integrity: sha512-rLfVLB4FgQneDr0dv1oddCVZmKjcJ6yX6mS4pU82Mq/Dt9a3cLZQ62pDBL4AUO+uVrCvtWz3ZFUL2HFAFJ/BXQ==} - zip-stream@6.0.1: - resolution: {integrity: sha512-zK7YHHz4ZXpW89AHXUPbQVGKI7uvkd3hzusTdotCg1UxyaVtg0zFJSTfW/Dq5f7OBBVnq6cZIaC8Ti4hb6dtCA==} - engines: {node: '>= 14'} - zod@3.22.3: resolution: {integrity: sha512-EjIevzuJRiRPbVH4mGc8nApb/lVLKVpmUhAaR5R5doKGfAnGJ6Gr3CViAVjP+4FWSxCsybeWQdcgCtbX+7oZug==} @@ -8488,9 +6561,8 @@ snapshots: '@cloudflare/workerd-windows-64@1.20251217.0': optional: true - '@cloudflare/workers-types@4.20251219.0': {} - - '@colors/colors@1.6.0': {} + '@cloudflare/workers-types@4.20251219.0': + optional: true '@cspotcode/source-map-support@0.8.1': dependencies: @@ -8518,17 +6590,6 @@ snapshots: '@csstools/css-tokenizer@3.0.4': {} - '@dabh/diagnostics@2.0.8': - dependencies: - '@so-ric/colorspace': 1.1.6 - enabled: 2.0.0 - kuler: 2.0.0 - - '@dependents/detective-less@5.0.1': - dependencies: - gonzales-pe: 4.3.0 - node-source-walk: 7.0.1 - '@docsearch/css@3.9.0': {} '@docsearch/react@3.9.0(@algolia/client-search@5.40.0)(@types/react@19.2.7)(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(search-insights@2.17.3)': @@ -8545,17 +6606,13 @@ snapshots: transitivePeerDependencies: - '@algolia/client-search' - '@edge-runtime/format@2.2.1': {} - - '@edge-runtime/node-utils@2.3.0': {} - - '@edge-runtime/ponyfill@2.4.2': {} - - '@edge-runtime/primitives@4.1.0': {} + '@edge-runtime/primitives@4.1.0': + optional: true '@edge-runtime/vm@3.2.0': dependencies: '@edge-runtime/primitives': 4.1.0 + optional: true '@elysiajs/node@1.4.2(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))': dependencies: @@ -8579,11 +6636,6 @@ snapshots: tslib: 2.8.1 optional: true - '@envelop/instrumentation@1.0.0': - dependencies: - '@whatwg-node/promise-helpers': 1.3.2 - tslib: 2.8.1 - '@esbuild/aix-ppc64@0.23.1': optional: true @@ -8890,18 +6942,12 @@ snapshots: '@esbuild/win32-x64@0.27.2': optional: true - '@fastify/accept-negotiator@2.0.1': {} - '@fastify/ajv-compiler@4.0.3': dependencies: ajv: 8.17.1 ajv-formats: 3.0.1(ajv@8.17.1) fast-uri: 3.1.0 - '@fastify/busboy@2.1.1': {} - - '@fastify/busboy@3.2.0': {} - '@fastify/error@4.2.0': {} '@fastify/fast-json-stringify-compiler@5.0.3': @@ -8934,183 +6980,81 @@ snapshots: dependencies: hono: 4.11.1 - '@humanwhocodes/momoa@2.0.4': {} - - '@iarna/toml@2.2.5': {} - - '@img/colour@1.0.0': {} - '@img/sharp-darwin-arm64@0.33.5': optionalDependencies: '@img/sharp-libvips-darwin-arm64': 1.0.4 optional: true - '@img/sharp-darwin-arm64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-darwin-arm64': 1.2.4 - optional: true - '@img/sharp-darwin-x64@0.33.5': optionalDependencies: '@img/sharp-libvips-darwin-x64': 1.0.4 optional: true - '@img/sharp-darwin-x64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-darwin-x64': 1.2.4 - optional: true - '@img/sharp-libvips-darwin-arm64@1.0.4': optional: true - '@img/sharp-libvips-darwin-arm64@1.2.4': - optional: true - '@img/sharp-libvips-darwin-x64@1.0.4': optional: true - '@img/sharp-libvips-darwin-x64@1.2.4': - optional: true - '@img/sharp-libvips-linux-arm64@1.0.4': optional: true - '@img/sharp-libvips-linux-arm64@1.2.4': - optional: true - '@img/sharp-libvips-linux-arm@1.0.5': optional: true - '@img/sharp-libvips-linux-arm@1.2.4': - optional: true - - '@img/sharp-libvips-linux-ppc64@1.2.4': - optional: true - - '@img/sharp-libvips-linux-riscv64@1.2.4': - optional: true - '@img/sharp-libvips-linux-s390x@1.0.4': optional: true - '@img/sharp-libvips-linux-s390x@1.2.4': - optional: true - '@img/sharp-libvips-linux-x64@1.0.4': optional: true - '@img/sharp-libvips-linux-x64@1.2.4': - optional: true - '@img/sharp-libvips-linuxmusl-arm64@1.0.4': optional: true - '@img/sharp-libvips-linuxmusl-arm64@1.2.4': - optional: true - '@img/sharp-libvips-linuxmusl-x64@1.0.4': optional: true - '@img/sharp-libvips-linuxmusl-x64@1.2.4': - optional: true - '@img/sharp-linux-arm64@0.33.5': optionalDependencies: '@img/sharp-libvips-linux-arm64': 1.0.4 optional: true - '@img/sharp-linux-arm64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-arm64': 1.2.4 - optional: true - '@img/sharp-linux-arm@0.33.5': optionalDependencies: '@img/sharp-libvips-linux-arm': 1.0.5 optional: true - '@img/sharp-linux-arm@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-arm': 1.2.4 - optional: true - - '@img/sharp-linux-ppc64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-ppc64': 1.2.4 - optional: true - - '@img/sharp-linux-riscv64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-riscv64': 1.2.4 - optional: true - '@img/sharp-linux-s390x@0.33.5': optionalDependencies: '@img/sharp-libvips-linux-s390x': 1.0.4 optional: true - '@img/sharp-linux-s390x@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-s390x': 1.2.4 - optional: true - '@img/sharp-linux-x64@0.33.5': optionalDependencies: '@img/sharp-libvips-linux-x64': 1.0.4 optional: true - '@img/sharp-linux-x64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linux-x64': 1.2.4 - optional: true - '@img/sharp-linuxmusl-arm64@0.33.5': optionalDependencies: '@img/sharp-libvips-linuxmusl-arm64': 1.0.4 optional: true - '@img/sharp-linuxmusl-arm64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linuxmusl-arm64': 1.2.4 - optional: true - '@img/sharp-linuxmusl-x64@0.33.5': optionalDependencies: '@img/sharp-libvips-linuxmusl-x64': 1.0.4 optional: true - '@img/sharp-linuxmusl-x64@0.34.5': - optionalDependencies: - '@img/sharp-libvips-linuxmusl-x64': 1.2.4 - optional: true - '@img/sharp-wasm32@0.33.5': dependencies: '@emnapi/runtime': 1.7.1 optional: true - '@img/sharp-wasm32@0.34.5': - dependencies: - '@emnapi/runtime': 1.7.1 - optional: true - - '@img/sharp-win32-arm64@0.34.5': - optional: true - '@img/sharp-win32-ia32@0.33.5': optional: true - '@img/sharp-win32-ia32@0.34.5': - optional: true - '@img/sharp-win32-x64@0.33.5': optional: true - '@img/sharp-win32-x64@0.34.5': - optional: true - - '@import-maps/resolve@2.0.0': {} - '@inquirer/external-editor@1.0.2(@types/node@22.19.1)': dependencies: chardet: 2.1.0 @@ -9251,338 +7195,6 @@ snapshots: '@tybys/wasm-util': 0.10.1 optional: true - '@netlify/ai@0.3.5(@netlify/api@14.0.12)': - dependencies: - '@netlify/api': 14.0.12 - - '@netlify/api@14.0.12': - dependencies: - '@netlify/open-api': 2.45.0 - node-fetch: 3.3.2 - p-wait-for: 5.0.2 - picoquery: 2.5.0 - - '@netlify/binary-info@1.0.0': {} - - '@netlify/blobs@10.4.4': - dependencies: - '@netlify/dev-utils': 4.3.3 - '@netlify/otel': 5.1.1 - '@netlify/runtime-utils': 2.2.1 - transitivePeerDependencies: - - supports-color - - '@netlify/cache@3.3.4': - dependencies: - '@netlify/runtime-utils': 2.2.1 - - '@netlify/config@24.2.0': - dependencies: - '@iarna/toml': 2.2.5 - '@netlify/api': 14.0.12 - '@netlify/headers-parser': 9.0.2 - '@netlify/redirect-parser': 15.0.3 - chalk: 5.6.2 - cron-parser: 4.9.0 - deepmerge: 4.3.1 - dot-prop: 9.0.0 - execa: 8.0.1 - fast-safe-stringify: 2.1.1 - figures: 6.1.0 - filter-obj: 6.1.0 - find-up: 7.0.0 - indent-string: 5.0.0 - is-plain-obj: 4.1.0 - map-obj: 5.0.2 - omit.js: 2.0.2 - p-locate: 6.0.0 - path-type: 6.0.0 - read-package-up: 11.0.0 - tomlify-j0.4: 3.0.0 - validate-npm-package-name: 5.0.1 - yaml: 2.8.2 - yargs: 17.7.2 - zod: 4.2.1 - - '@netlify/dev-utils@4.3.3': - dependencies: - '@whatwg-node/server': 0.10.17 - ansis: 4.2.0 - chokidar: 4.0.3 - decache: 4.6.2 - dettle: 1.0.5 - dot-prop: 9.0.0 - empathic: 2.0.0 - env-paths: 3.0.0 - image-size: 2.0.2 - js-image-generator: 1.0.4 - parse-gitignore: 2.0.0 - semver: 7.7.3 - tmp-promise: 3.0.3 - uuid: 13.0.0 - write-file-atomic: 5.0.1 - - '@netlify/dev@4.8.5(@netlify/api@14.0.12)(rollup@4.53.5)': - dependencies: - '@netlify/ai': 0.3.5(@netlify/api@14.0.12) - '@netlify/blobs': 10.4.4 - '@netlify/config': 24.2.0 - '@netlify/dev-utils': 4.3.3 - '@netlify/edge-functions-dev': 1.0.7 - '@netlify/functions-dev': 1.1.5(rollup@4.53.5) - '@netlify/headers': 2.1.3 - '@netlify/images': 1.3.3(@netlify/blobs@10.4.4) - '@netlify/redirects': 3.1.4 - '@netlify/runtime': 4.1.12 - '@netlify/static': 3.1.3 - ulid: 3.0.2 - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@deno/kv' - - '@netlify/api' - - '@planetscale/database' - - '@upstash/redis' - - '@vercel/blob' - - '@vercel/functions' - - '@vercel/kv' - - aws4fetch - - bare-abort-controller - - db0 - - encoding - - idb-keyval - - ioredis - - react-native-b4a - - rollup - - supports-color - - uploadthing - - '@netlify/edge-bundler@14.9.2': - dependencies: - '@import-maps/resolve': 2.0.0 - ajv: 8.17.1 - ajv-errors: 3.0.0(ajv@8.17.1) - better-ajv-errors: 1.2.0(ajv@8.17.1) - common-path-prefix: 3.0.0 - env-paths: 3.0.0 - esbuild: 0.27.2 - execa: 8.0.1 - find-up: 7.0.0 - get-port: 7.1.0 - node-stream-zip: 1.15.0 - p-retry: 6.2.1 - p-wait-for: 5.0.2 - parse-imports: 2.2.1 - path-key: 4.0.0 - semver: 7.7.3 - tar: 7.5.1 - tmp-promise: 3.0.3 - urlpattern-polyfill: 8.0.2 - uuid: 11.1.0 - - '@netlify/edge-functions-bootstrap@2.16.0': {} - - '@netlify/edge-functions-dev@1.0.7': - dependencies: - '@netlify/dev-utils': 4.3.3 - '@netlify/edge-bundler': 14.9.2 - '@netlify/edge-functions': 3.0.3 - '@netlify/edge-functions-bootstrap': 2.16.0 - '@netlify/runtime-utils': 2.2.1 - get-port: 7.1.0 - - '@netlify/edge-functions@3.0.3': - dependencies: - '@netlify/types': 2.3.0 - - '@netlify/functions-dev@1.1.5(rollup@4.53.5)': - dependencies: - '@netlify/blobs': 10.4.4 - '@netlify/dev-utils': 4.3.3 - '@netlify/functions': 5.1.1 - '@netlify/zip-it-and-ship-it': 14.1.17(rollup@4.53.5) - cron-parser: 4.9.0 - decache: 4.6.2 - extract-zip: 2.0.1 - is-stream: 4.0.1 - jwt-decode: 4.0.0 - lambda-local: 2.2.0 - read-package-up: 11.0.0 - semver: 7.7.3 - source-map-support: 0.5.21 - transitivePeerDependencies: - - bare-abort-controller - - encoding - - react-native-b4a - - rollup - - supports-color - - '@netlify/functions@5.1.1': - dependencies: - '@netlify/types': 2.3.0 - - '@netlify/headers-parser@9.0.2': - dependencies: - '@iarna/toml': 2.2.5 - escape-string-regexp: 5.0.0 - fast-safe-stringify: 2.1.1 - is-plain-obj: 4.1.0 - map-obj: 5.0.2 - path-exists: 5.0.0 - - '@netlify/headers@2.1.3': - dependencies: - '@netlify/headers-parser': 9.0.2 - - '@netlify/images@1.3.3(@netlify/blobs@10.4.4)': - dependencies: - ipx: 3.1.1(@netlify/blobs@10.4.4) - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@deno/kv' - - '@netlify/blobs' - - '@planetscale/database' - - '@upstash/redis' - - '@vercel/blob' - - '@vercel/functions' - - '@vercel/kv' - - aws4fetch - - db0 - - idb-keyval - - ioredis - - uploadthing - - '@netlify/open-api@2.45.0': {} - - '@netlify/otel@5.1.1': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/instrumentation': 0.203.0(@opentelemetry/api@1.9.0) - '@opentelemetry/resources': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/sdk-trace-node': 1.30.1(@opentelemetry/api@1.9.0) - transitivePeerDependencies: - - supports-color - - '@netlify/redirect-parser@15.0.3': - dependencies: - '@iarna/toml': 2.2.5 - fast-safe-stringify: 2.1.1 - is-plain-obj: 4.1.0 - path-exists: 5.0.0 - - '@netlify/redirects@3.1.4': - dependencies: - '@netlify/dev-utils': 4.3.3 - '@netlify/redirect-parser': 15.0.3 - cookie: 1.1.1 - jsonwebtoken: 9.0.2 - netlify-redirector: 0.5.0 - - '@netlify/runtime-utils@2.2.1': {} - - '@netlify/runtime@4.1.12': - dependencies: - '@netlify/blobs': 10.4.4 - '@netlify/cache': 3.3.4 - '@netlify/runtime-utils': 2.2.1 - '@netlify/types': 2.3.0 - transitivePeerDependencies: - - supports-color - - '@netlify/serverless-functions-api@2.8.2': {} - - '@netlify/static@3.1.3': - dependencies: - mime-types: 3.0.1 - - '@netlify/types@2.3.0': {} - - '@netlify/vite-plugin@2.7.17(@netlify/api@14.0.12)(rollup@4.53.5)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': - dependencies: - '@netlify/dev': 4.8.5(@netlify/api@14.0.12)(rollup@4.53.5) - '@netlify/dev-utils': 4.3.3 - dedent: 1.7.0 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@deno/kv' - - '@netlify/api' - - '@planetscale/database' - - '@upstash/redis' - - '@vercel/blob' - - '@vercel/functions' - - '@vercel/kv' - - aws4fetch - - babel-plugin-macros - - bare-abort-controller - - db0 - - encoding - - idb-keyval - - ioredis - - react-native-b4a - - rollup - - supports-color - - uploadthing - - '@netlify/zip-it-and-ship-it@14.1.17(rollup@4.53.5)': - dependencies: - '@babel/parser': 7.28.5 - '@babel/types': 7.28.5 - '@netlify/binary-info': 1.0.0 - '@netlify/serverless-functions-api': 2.8.2 - '@vercel/nft': 0.29.4(rollup@4.53.5) - archiver: 7.0.1 - common-path-prefix: 3.0.0 - copy-file: 11.1.0 - es-module-lexer: 1.7.0 - esbuild: 0.27.2 - execa: 8.0.1 - fast-glob: 3.3.3 - filter-obj: 6.1.0 - find-up: 7.0.0 - is-path-inside: 4.0.0 - junk: 4.0.1 - locate-path: 7.2.0 - merge-options: 3.0.4 - minimatch: 9.0.5 - normalize-path: 3.0.0 - p-map: 7.0.4 - path-exists: 5.0.0 - precinct: 12.2.0 - require-package-name: 2.0.1 - resolve: 2.0.0-next.5 - semver: 7.7.3 - tmp-promise: 3.0.3 - toml: 3.0.0 - unixify: 1.0.0 - urlpattern-polyfill: 8.0.2 - yargs: 17.7.2 - zod: 3.25.76 - transitivePeerDependencies: - - bare-abort-controller - - encoding - - react-native-b4a - - rollup - - supports-color - '@nodelib/fs.scandir@2.1.5': dependencies: '@nodelib/fs.stat': 2.0.5 @@ -9610,135 +7222,92 @@ snapshots: '@oozcitak/infra': 2.0.1 '@oozcitak/util': 9.0.4 - '@oozcitak/util@9.0.4': {} - - '@opentelemetry/api-logs@0.203.0': - dependencies: - '@opentelemetry/api': 1.9.0 - - '@opentelemetry/api@1.9.0': {} - - '@opentelemetry/context-async-hooks@1.30.1(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - - '@opentelemetry/core@1.30.1(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/semantic-conventions': 1.28.0 - - '@opentelemetry/instrumentation@0.203.0(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/api-logs': 0.203.0 - import-in-the-middle: 1.15.0 - require-in-the-middle: 7.5.2 - transitivePeerDependencies: - - supports-color - - '@opentelemetry/propagator-b3@1.30.1(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.30.1(@opentelemetry/api@1.9.0) - - '@opentelemetry/propagator-jaeger@1.30.1(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.30.1(@opentelemetry/api@1.9.0) - - '@opentelemetry/resources@1.30.1(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.28.0 - - '@opentelemetry/sdk-trace-base@1.30.1(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/resources': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.28.0 - - '@opentelemetry/sdk-trace-node@1.30.1(@opentelemetry/api@1.9.0)': - dependencies: - '@opentelemetry/api': 1.9.0 - '@opentelemetry/context-async-hooks': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/core': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/propagator-b3': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/propagator-jaeger': 1.30.1(@opentelemetry/api@1.9.0) - '@opentelemetry/sdk-trace-base': 1.30.1(@opentelemetry/api@1.9.0) - semver: 7.7.3 - - '@opentelemetry/semantic-conventions@1.28.0': {} - - '@oxc-project/types@0.103.0': {} - - '@oxc-project/types@0.98.0': {} - - '@parcel/watcher-android-arm64@2.5.1': - optional: true - - '@parcel/watcher-darwin-arm64@2.5.1': - optional: true - - '@parcel/watcher-darwin-x64@2.5.1': - optional: true - - '@parcel/watcher-freebsd-x64@2.5.1': - optional: true - - '@parcel/watcher-linux-arm-glibc@2.5.1': - optional: true - - '@parcel/watcher-linux-arm-musl@2.5.1': - optional: true - - '@parcel/watcher-linux-arm64-glibc@2.5.1': - optional: true - - '@parcel/watcher-linux-arm64-musl@2.5.1': - optional: true - - '@parcel/watcher-linux-x64-glibc@2.5.1': - optional: true - - '@parcel/watcher-linux-x64-musl@2.5.1': - optional: true - - '@parcel/watcher-wasm@2.5.1': - dependencies: - is-glob: 4.0.3 - micromatch: 4.0.8 + '@oozcitak/util@9.0.4': {} - '@parcel/watcher-win32-arm64@2.5.1': - optional: true + '@oxc-project/types@0.103.0': {} - '@parcel/watcher-win32-ia32@2.5.1': - optional: true + '@oxc-project/types@0.98.0': {} - '@parcel/watcher-win32-x64@2.5.1': - optional: true + '@photonjs/cloudflare@0.1.13(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0))': + dependencies: + '@cloudflare/vite-plugin': 1.19.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0)) + '@photonjs/core': 0.1.21(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@universal-middleware/cloudflare': 0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + transitivePeerDependencies: + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@webroute/route' + - bufferutil + - elysia + - fastify + - h3 + - hono + - srvx + - utf-8-validate + - vite + - workerd + - wrangler - '@parcel/watcher@2.5.1': + '@photonjs/core@0.1.21(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: - detect-libc: 1.0.3 - is-glob: 4.0.3 - micromatch: 4.0.8 - node-addon-api: 7.1.1 + '@brillout/vite-plugin-server-entry': 0.7.15 + '@universal-middleware/cloudflare': 0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/compress': 0.2.34 + '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/sirv': 0.1.24 + estree-walker: 3.0.3 + ts-deepmerge: 7.0.3 + zod: 4.2.1 optionalDependencies: - '@parcel/watcher-android-arm64': 2.5.1 - '@parcel/watcher-darwin-arm64': 2.5.1 - '@parcel/watcher-darwin-x64': 2.5.1 - '@parcel/watcher-freebsd-x64': 2.5.1 - '@parcel/watcher-linux-arm-glibc': 2.5.1 - '@parcel/watcher-linux-arm-musl': 2.5.1 - '@parcel/watcher-linux-arm64-glibc': 2.5.1 - '@parcel/watcher-linux-arm64-musl': 2.5.1 - '@parcel/watcher-linux-x64-glibc': 2.5.1 - '@parcel/watcher-linux-x64-musl': 2.5.1 - '@parcel/watcher-win32-arm64': 2.5.1 - '@parcel/watcher-win32-ia32': 2.5.1 - '@parcel/watcher-win32-x64': 2.5.1 + vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + transitivePeerDependencies: + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@webroute/route' + - elysia + - fastify + - h3 + - hono + - srvx + + '@photonjs/vercel@0.1.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(rollup@4.53.5)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + dependencies: + '@brillout/libassert': 0.5.8 + '@manypkg/find-root': 3.1.0 + '@photonjs/core': link:packages/core + '@photonjs/runtime': link:packages/runtime + '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/vercel': 0.4.29(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@vercel/build-utils': 13.2.4 + '@vercel/nft': 1.1.1(rollup@4.53.5) + '@vercel/routing-utils': 5.3.1 + '@vite-plugin-vercel/schemas': 1.0.0 + convert-route: 0.1.2 + esbuild: 0.27.2 + fast-glob: 3.3.3 + magicast: 0.5.1 + path-to-regexp: 8.3.0 + strip-ansi: 7.1.2 + vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite-plugin-wasm: 3.5.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + transitivePeerDependencies: + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@universal-middleware/h3' + - '@webroute/route' + - elysia + - encoding + - express + - fastify + - h3 + - hono + - rollup + - srvx + - supports-color '@pinojs/redact@0.4.0': {} @@ -9946,11 +7515,6 @@ snapshots: '@sindresorhus/is@7.1.0': {} - '@so-ric/colorspace@1.1.6': - dependencies: - color: 5.0.3 - text-hex: 1.0.0 - '@solid-primitives/event-listener@2.4.3(solid-js@1.9.10)': dependencies: '@solid-primitives/utils': 6.3.2(solid-js@1.9.10) @@ -10490,21 +8054,6 @@ snapshots: '@tokenizer/token@0.3.0': {} - '@ts-morph/common@0.11.1': - dependencies: - fast-glob: 3.3.3 - minimatch: 3.1.2 - mkdirp: 1.0.4 - path-browserify: 1.0.1 - - '@tsconfig/node10@1.0.11': {} - - '@tsconfig/node12@1.0.11': {} - - '@tsconfig/node14@1.0.3': {} - - '@tsconfig/node16@1.0.4': {} - '@tybys/wasm-util@0.10.1': dependencies: tslib: 2.8.1 @@ -10584,8 +8133,6 @@ snapshots: '@types/http-errors@2.0.5': {} - '@types/json-schema@7.0.15': {} - '@types/mdast@4.0.4': dependencies: '@types/unist': 3.0.3 @@ -10596,18 +8143,10 @@ snapshots: '@types/node@12.20.55': {} - '@types/node@16.18.11': {} - - '@types/node@20.19.25': - dependencies: - undici-types: 6.21.0 - '@types/node@22.19.1': dependencies: undici-types: 6.21.0 - '@types/normalize-package-data@2.4.4': {} - '@types/qs@6.14.0': {} '@types/range-parser@1.2.7': {} @@ -10620,8 +8159,6 @@ snapshots: dependencies: csstype: 3.2.3 - '@types/retry@0.12.2': {} - '@types/send@1.2.0': dependencies: '@types/node': 22.19.1 @@ -10631,53 +8168,26 @@ snapshots: '@types/http-errors': 2.0.5 '@types/node': 22.19.1 - '@types/triple-beam@1.3.5': {} - '@types/unist@2.0.11': {} '@types/unist@3.0.3': {} - '@types/yauzl@2.10.3': - dependencies: - '@types/node': 22.19.1 - optional: true - - '@typescript-eslint/project-service@8.48.1(typescript@5.9.3)': - dependencies: - '@typescript-eslint/tsconfig-utils': 8.48.1(typescript@5.9.3) - '@typescript-eslint/types': 8.48.1 - debug: 4.4.3 - typescript: 5.9.3 - transitivePeerDependencies: - - supports-color - - '@typescript-eslint/tsconfig-utils@8.48.1(typescript@5.9.3)': - dependencies: - typescript: 5.9.3 - - '@typescript-eslint/types@8.48.1': {} + '@ungap/structured-clone@1.3.0': {} - '@typescript-eslint/typescript-estree@8.48.1(typescript@5.9.3)': + '@universal-deploy/store@0.0.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@typescript-eslint/project-service': 8.48.1(typescript@5.9.3) - '@typescript-eslint/tsconfig-utils': 8.48.1(typescript@5.9.3) - '@typescript-eslint/types': 8.48.1 - '@typescript-eslint/visitor-keys': 8.48.1 - debug: 4.4.3 - minimatch: 9.0.5 - semver: 7.7.3 - tinyglobby: 0.2.15 - ts-api-utils: 2.1.0(typescript@5.9.3) - typescript: 5.9.3 + '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + rou3: 0.7.12 transitivePeerDependencies: - - supports-color - - '@typescript-eslint/visitor-keys@8.48.1': - dependencies: - '@typescript-eslint/types': 8.48.1 - eslint-visitor-keys: 4.2.1 - - '@ungap/structured-clone@1.3.0': {} + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@webroute/route' + - elysia + - fastify + - h3 + - hono + - srvx '@universal-middleware/cloudflare@0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: @@ -10834,27 +8344,6 @@ snapshots: '@vercel/build-utils@13.2.4': {} - '@vercel/error-utils@2.0.3': {} - - '@vercel/nft@0.29.4(rollup@4.53.5)': - dependencies: - '@mapbox/node-pre-gyp': 2.0.0 - '@rollup/pluginutils': 5.3.0(rollup@4.53.5) - acorn: 8.15.0 - acorn-import-attributes: 1.9.5(acorn@8.15.0) - async-sema: 3.1.1 - bindings: 1.5.0 - estree-walker: 2.0.2 - glob: 10.5.0 - graceful-fs: 4.2.11 - node-gyp-build: 4.8.4 - picomatch: 4.0.3 - resolve-from: 5.0.0 - transitivePeerDependencies: - - encoding - - rollup - - supports-color - '@vercel/nft@0.30.4(rollup@4.53.5)': dependencies: '@mapbox/node-pre-gyp': 2.0.0 @@ -10893,38 +8382,6 @@ snapshots: - rollup - supports-color - '@vercel/node@5.5.16(@swc/core@1.13.5)(rollup@4.53.5)': - dependencies: - '@edge-runtime/node-utils': 2.3.0 - '@edge-runtime/primitives': 4.1.0 - '@edge-runtime/vm': 3.2.0 - '@types/node': 16.18.11 - '@vercel/build-utils': 13.2.4 - '@vercel/error-utils': 2.0.3 - '@vercel/nft': 1.1.1(rollup@4.53.5) - '@vercel/static-config': 3.1.2 - async-listen: 3.0.0 - cjs-module-lexer: 1.2.3 - edge-runtime: 2.5.9 - es-module-lexer: 1.4.1 - esbuild: 0.14.47 - etag: 1.8.1 - mime-types: 2.1.35 - node-fetch: 2.6.9 - path-to-regexp: 6.1.0 - path-to-regexp-updated: path-to-regexp@6.3.0 - ts-morph: 12.0.0 - ts-node: 10.9.1(@swc/core@1.13.5)(@types/node@16.18.11)(typescript@4.9.5) - typescript: 4.9.5 - typescript5: typescript@5.9.3 - undici: 5.28.4 - transitivePeerDependencies: - - '@swc/core' - - '@swc/wasm' - - encoding - - rollup - - supports-color - '@vercel/routing-utils@5.3.1': dependencies: path-to-regexp: 6.1.0 @@ -10932,12 +8389,6 @@ snapshots: optionalDependencies: ajv: 6.12.6 - '@vercel/static-config@3.1.2': - dependencies: - ajv: 8.6.3 - json-schema-to-ts: 1.6.4 - ts-morph: 12.0.0 - '@vikejs/biome-config@2.0.1(@biomejs/biome@2.3.10)': dependencies: '@biomejs/biome': 2.3.10 @@ -11050,41 +8501,8 @@ snapshots: dependencies: '@vue/compiler-core': 3.5.22 - '@whatwg-node/disposablestack@0.0.6': - dependencies: - '@whatwg-node/promise-helpers': 1.3.2 - tslib: 2.8.1 - - '@whatwg-node/fetch@0.10.13': - dependencies: - '@whatwg-node/node-fetch': 0.8.4 - urlpattern-polyfill: 10.1.0 - - '@whatwg-node/node-fetch@0.8.4': - dependencies: - '@fastify/busboy': 3.2.0 - '@whatwg-node/disposablestack': 0.0.6 - '@whatwg-node/promise-helpers': 1.3.2 - tslib: 2.8.1 - - '@whatwg-node/promise-helpers@1.3.2': - dependencies: - tslib: 2.8.1 - - '@whatwg-node/server@0.10.17': - dependencies: - '@envelop/instrumentation': 1.0.0 - '@whatwg-node/disposablestack': 0.0.6 - '@whatwg-node/fetch': 0.10.13 - '@whatwg-node/promise-helpers': 1.3.2 - tslib: 2.8.1 - abbrev@3.0.1: {} - abort-controller@3.0.0: - dependencies: - event-target-shim: 5.0.1 - abstract-logging@2.0.1: {} accepts@2.0.0: @@ -11102,20 +8520,12 @@ snapshots: acorn-walk@8.3.2: {} - acorn-walk@8.3.4: - dependencies: - acorn: 8.15.0 - acorn@8.14.0: {} acorn@8.15.0: {} agent-base@7.1.4: {} - ajv-errors@3.0.0(ajv@8.17.1): - dependencies: - ajv: 8.17.1 - ajv-formats@3.0.1(ajv@8.17.1): optionalDependencies: ajv: 8.17.1 @@ -11135,13 +8545,6 @@ snapshots: json-schema-traverse: 1.0.0 require-from-string: 2.0.2 - ajv@8.6.3: - dependencies: - fast-deep-equal: 3.1.3 - json-schema-traverse: 1.0.0 - require-from-string: 2.0.2 - uri-js: 4.4.1 - algoliasearch@5.40.0: dependencies: '@algolia/abtesting': 1.6.0 @@ -11180,31 +8583,6 @@ snapshots: normalize-path: 3.0.0 picomatch: 2.3.1 - archiver-utils@5.0.2: - dependencies: - glob: 10.5.0 - graceful-fs: 4.2.11 - is-stream: 2.0.1 - lazystream: 1.0.1 - lodash: 4.17.21 - normalize-path: 3.0.0 - readable-stream: 4.7.0 - - archiver@7.0.1: - dependencies: - archiver-utils: 5.0.2 - async: 3.2.6 - buffer-crc32: 1.0.0 - readable-stream: 4.7.0 - readdir-glob: 1.1.3 - tar-stream: 3.1.7 - zip-stream: 6.0.1 - transitivePeerDependencies: - - bare-abort-controller - - react-native-b4a - - arg@4.1.3: {} - argparse@1.0.10: dependencies: sprintf-js: 1.0.3 @@ -11241,8 +8619,6 @@ snapshots: '@babel/parser': 7.28.5 pathe: 2.0.3 - ast-module-types@6.0.1: {} - ast-types@0.16.1: dependencies: tslib: 2.8.1 @@ -11251,14 +8627,8 @@ snapshots: async-function@1.0.0: {} - async-listen@3.0.0: {} - - async-listen@3.0.1: {} - async-sema@3.1.1: {} - async@3.2.6: {} - atomic-sleep@1.0.0: {} available-typed-arrays@1.0.7: @@ -11270,8 +8640,6 @@ snapshots: '@fastify/error': 4.2.0 fastq: 1.19.1 - b4a@1.7.3: {} - babel-dead-code-elimination@1.0.10: dependencies: '@babel/core': 7.28.5 @@ -11285,21 +8653,8 @@ snapshots: balanced-match@1.0.2: {} - bare-events@2.8.2: {} - - base64-js@1.5.1: {} - baseline-browser-mapping@2.9.15: {} - better-ajv-errors@1.2.0(ajv@8.17.1): - dependencies: - '@babel/code-frame': 7.27.1 - '@humanwhocodes/momoa': 2.0.4 - ajv: 8.17.1 - chalk: 4.1.2 - jsonpointer: 5.0.1 - leven: 3.1.0 - better-path-resolve@1.0.0: dependencies: is-windows: 1.0.2 @@ -11334,11 +8689,6 @@ snapshots: boolbase@1.0.0: {} - brace-expansion@1.1.12: - dependencies: - balanced-match: 1.0.2 - concat-map: 0.0.1 - brace-expansion@2.0.2: dependencies: balanced-match: 1.0.2 @@ -11355,19 +8705,8 @@ snapshots: node-releases: 2.0.26 update-browserslist-db: 1.1.3(browserslist@4.26.3) - buffer-crc32@0.2.13: {} - - buffer-crc32@1.0.0: {} - - buffer-equal-constant-time@1.0.1: {} - buffer-from@1.1.2: {} - buffer@6.0.3: - dependencies: - base64-js: 1.5.1 - ieee754: 1.2.1 - bun-types@1.3.3: dependencies: '@types/node': 22.19.1 @@ -11393,8 +8732,6 @@ snapshots: call-bind-apply-helpers: 1.0.2 get-intrinsic: 1.3.0 - callsite@1.0.0: {} - caniuse-lite@1.0.30001751: {} ccount@2.0.1: {} @@ -11417,11 +8754,6 @@ snapshots: loupe: 3.2.1 pathval: 2.0.1 - chalk@4.1.2: - dependencies: - ansi-styles: 4.3.0 - supports-color: 7.2.0 - chalk@5.6.2: {} character-entities-html4@2.1.0: {} @@ -11475,93 +8807,32 @@ snapshots: optionalDependencies: fsevents: 2.3.3 - chokidar@4.0.3: - dependencies: - readdirp: 4.1.2 - chownr@3.0.0: {} ci-info@3.9.0: {} - citty@0.1.6: - dependencies: - consola: 3.4.2 - - cjs-module-lexer@1.2.3: {} - - clipboardy@4.0.0: - dependencies: - execa: 8.0.1 - is-wsl: 3.1.0 - is64bit: 2.0.0 - - cliui@8.0.1: - dependencies: - string-width: 4.2.3 - strip-ansi: 6.0.1 - wrap-ansi: 7.0.0 - clsx@2.1.1: {} - code-block-writer@10.1.1: {} - collapse-white-space@2.1.0: {} color-convert@2.0.1: dependencies: color-name: 1.1.4 - color-convert@3.1.3: - dependencies: - color-name: 2.1.0 - color-name@1.1.4: {} - color-name@2.1.0: {} - color-string@1.9.1: dependencies: color-name: 1.1.4 simple-swizzle: 0.2.4 - color-string@2.1.4: - dependencies: - color-name: 2.1.0 - color@4.2.3: dependencies: color-convert: 2.0.1 color-string: 1.9.1 - color@5.0.3: - dependencies: - color-convert: 3.1.3 - color-string: 2.1.4 - comma-separated-tokens@2.0.3: {} - commander@10.0.1: {} - - commander@11.1.0: {} - - commander@12.1.0: {} - - commander@2.20.3: {} - - common-path-prefix@3.0.0: {} - - compress-commons@6.0.2: - dependencies: - crc-32: 1.2.2 - crc32-stream: 6.0.0 - is-stream: 2.0.1 - normalize-path: 3.0.0 - readable-stream: 4.7.0 - - concat-map@0.0.1: {} - - confbox@0.1.8: {} - confbox@0.2.2: {} consola@3.4.2: {} @@ -11572,41 +8843,19 @@ snapshots: content-type@1.0.5: {} - convert-hrtime@3.0.0: {} - convert-route@0.1.2: {} - convert-source-map@2.0.0: {} - - cookie-es@1.2.2: {} - - cookie-es@2.0.0: {} - - cookie-signature@1.2.2: {} - - cookie@0.7.2: {} - - cookie@1.1.1: {} - - copy-file@11.1.0: - dependencies: - graceful-fs: 4.2.11 - p-event: 6.0.1 + convert-source-map@2.0.0: {} - core-util-is@1.0.3: {} + cookie-es@1.2.2: {} - crc-32@1.2.2: {} + cookie-es@2.0.0: {} - crc32-stream@6.0.0: - dependencies: - crc-32: 1.2.2 - readable-stream: 4.7.0 + cookie-signature@1.2.2: {} - create-require@1.1.1: {} + cookie@0.7.2: {} - cron-parser@4.9.0: - dependencies: - luxon: 3.7.2 + cookie@1.1.1: {} cross-spawn@7.0.6: dependencies: @@ -11630,11 +8879,6 @@ snapshots: domutils: 3.2.2 nth-check: 2.1.1 - css-tree@2.2.1: - dependencies: - mdn-data: 2.0.28 - source-map-js: 1.2.1 - css-tree@3.1.0: dependencies: mdn-data: 2.12.2 @@ -11642,12 +8886,6 @@ snapshots: css-what@6.2.2: {} - cssfilter@0.0.10: {} - - csso@5.0.5: - dependencies: - css-tree: 2.2.1 - cssstyle@5.3.3: dependencies: '@asamuzakjp/css-color': 4.1.0 @@ -11656,8 +8894,6 @@ snapshots: csstype@3.2.3: {} - data-uri-to-buffer@4.0.1: {} - data-urls@6.0.0: dependencies: whatwg-mimetype: 4.0.0 @@ -11685,26 +8921,18 @@ snapshots: dependencies: ms: 2.1.3 - decache@4.6.2: - dependencies: - callsite: 1.0.0 - decimal.js@10.6.0: {} decode-named-character-reference@1.2.0: dependencies: character-entities: 2.0.2 - dedent@1.7.0: {} - deep-eql@4.1.4: dependencies: type-detect: 4.1.0 deep-eql@5.0.2: {} - deepmerge@4.3.1: {} - define-data-property@1.1.4: dependencies: es-define-property: 1.0.1 @@ -11727,68 +8955,8 @@ snapshots: detect-indent@6.1.0: {} - detect-libc@1.0.3: {} - detect-libc@2.1.2: {} - detective-amd@6.0.1: - dependencies: - ast-module-types: 6.0.1 - escodegen: 2.1.0 - get-amd-module-type: 6.0.1 - node-source-walk: 7.0.1 - - detective-cjs@6.0.1: - dependencies: - ast-module-types: 6.0.1 - node-source-walk: 7.0.1 - - detective-es6@5.0.1: - dependencies: - node-source-walk: 7.0.1 - - detective-postcss@7.0.1(postcss@8.5.6): - dependencies: - is-url: 1.2.4 - postcss: 8.5.6 - postcss-values-parser: 6.0.2(postcss@8.5.6) - - detective-sass@6.0.1: - dependencies: - gonzales-pe: 4.3.0 - node-source-walk: 7.0.1 - - detective-scss@5.0.1: - dependencies: - gonzales-pe: 4.3.0 - node-source-walk: 7.0.1 - - detective-stylus@5.0.1: {} - - detective-typescript@14.0.0(typescript@5.9.3): - dependencies: - '@typescript-eslint/typescript-estree': 8.48.1(typescript@5.9.3) - ast-module-types: 6.0.1 - node-source-walk: 7.0.1 - typescript: 5.9.3 - transitivePeerDependencies: - - supports-color - - detective-vue2@2.2.0(typescript@5.9.3): - dependencies: - '@dependents/detective-less': 5.0.1 - '@vue/compiler-sfc': 3.5.22 - detective-es6: 5.0.1 - detective-sass: 6.0.1 - detective-scss: 5.0.1 - detective-stylus: 5.0.1 - detective-typescript: 14.0.0(typescript@5.9.3) - typescript: 5.9.3 - transitivePeerDependencies: - - supports-color - - dettle@1.0.5: {} - detype@1.1.3: dependencies: '@babel/core': 7.28.5 @@ -11808,8 +8976,6 @@ snapshots: dependencies: dequal: 2.0.3 - diff@4.0.2: {} - diff@8.0.2: {} dir-glob@3.0.1: @@ -11836,12 +9002,6 @@ snapshots: domelementtype: 2.3.0 domhandler: 5.0.3 - dot-prop@9.0.0: - dependencies: - type-fest: 4.41.0 - - dotenv@16.6.1: {} - dts-resolver@2.1.3: {} dunder-proto@1.0.1: @@ -11852,22 +9012,6 @@ snapshots: eastasianwidth@0.2.0: {} - ecdsa-sig-formatter@1.0.11: - dependencies: - safe-buffer: 5.2.1 - - edge-runtime@2.5.9: - dependencies: - '@edge-runtime/format': 2.2.1 - '@edge-runtime/ponyfill': 2.4.2 - '@edge-runtime/vm': 3.2.0 - async-listen: 3.0.1 - mri: 1.2.0 - picocolors: 1.0.0 - pretty-ms: 7.0.1 - signal-exit: 4.0.2 - time-span: 4.0.0 - ee-first@1.1.1: {} electron-to-chromium@1.5.237: {} @@ -11891,8 +9035,6 @@ snapshots: empathic@2.0.0: {} - enabled@2.0.0: {} - encodeurl@2.0.0: {} encoding-sniffer@0.2.1: @@ -11900,10 +9042,6 @@ snapshots: iconv-lite: 0.6.3 whatwg-encoding: 3.1.1 - end-of-stream@1.4.5: - dependencies: - once: 1.4.0 - enhanced-resolve@5.18.3: dependencies: graceful-fs: 4.2.11 @@ -11918,8 +9056,6 @@ snapshots: entities@6.0.1: {} - env-paths@3.0.0: {} - error-stack-parser-es@1.0.5: {} es-abstract@1.24.0: @@ -11983,8 +9119,6 @@ snapshots: es-errors@1.3.0: {} - es-module-lexer@1.4.1: {} - es-module-lexer@1.7.0: {} es-object-atoms@1.1.1: @@ -12004,89 +9138,6 @@ snapshots: is-date-object: 1.1.0 is-symbol: 1.1.1 - esbuild-android-64@0.14.47: - optional: true - - esbuild-android-arm64@0.14.47: - optional: true - - esbuild-darwin-64@0.14.47: - optional: true - - esbuild-darwin-arm64@0.14.47: - optional: true - - esbuild-freebsd-64@0.14.47: - optional: true - - esbuild-freebsd-arm64@0.14.47: - optional: true - - esbuild-linux-32@0.14.47: - optional: true - - esbuild-linux-64@0.14.47: - optional: true - - esbuild-linux-arm64@0.14.47: - optional: true - - esbuild-linux-arm@0.14.47: - optional: true - - esbuild-linux-mips64le@0.14.47: - optional: true - - esbuild-linux-ppc64le@0.14.47: - optional: true - - esbuild-linux-riscv64@0.14.47: - optional: true - - esbuild-linux-s390x@0.14.47: - optional: true - - esbuild-netbsd-64@0.14.47: - optional: true - - esbuild-openbsd-64@0.14.47: - optional: true - - esbuild-sunos-64@0.14.47: - optional: true - - esbuild-windows-32@0.14.47: - optional: true - - esbuild-windows-64@0.14.47: - optional: true - - esbuild-windows-arm64@0.14.47: - optional: true - - esbuild@0.14.47: - optionalDependencies: - esbuild-android-64: 0.14.47 - esbuild-android-arm64: 0.14.47 - esbuild-darwin-64: 0.14.47 - esbuild-darwin-arm64: 0.14.47 - esbuild-freebsd-64: 0.14.47 - esbuild-freebsd-arm64: 0.14.47 - esbuild-linux-32: 0.14.47 - esbuild-linux-64: 0.14.47 - esbuild-linux-arm: 0.14.47 - esbuild-linux-arm64: 0.14.47 - esbuild-linux-mips64le: 0.14.47 - esbuild-linux-ppc64le: 0.14.47 - esbuild-linux-riscv64: 0.14.47 - esbuild-linux-s390x: 0.14.47 - esbuild-netbsd-64: 0.14.47 - esbuild-openbsd-64: 0.14.47 - esbuild-sunos-64: 0.14.47 - esbuild-windows-32: 0.14.47 - esbuild-windows-64: 0.14.47 - esbuild-windows-arm64: 0.14.47 - esbuild@0.23.1: optionalDependencies: '@esbuild/aix-ppc64': 0.23.1 @@ -12207,20 +9258,8 @@ snapshots: escape-string-regexp@5.0.0: {} - escodegen@2.1.0: - dependencies: - esprima: 4.0.1 - estraverse: 5.3.0 - esutils: 2.0.3 - optionalDependencies: - source-map: 0.6.1 - - eslint-visitor-keys@4.2.1: {} - esprima@4.0.1: {} - estraverse@5.3.0: {} - estree-util-attach-comments@3.0.0: dependencies: '@types/estree': 1.0.8 @@ -12251,36 +9290,12 @@ snapshots: dependencies: '@types/estree': 1.0.8 - esutils@2.0.3: {} - etag@1.8.1: {} - event-target-shim@5.0.1: {} - - events-universal@1.0.1: - dependencies: - bare-events: 2.8.2 - transitivePeerDependencies: - - bare-abort-controller - - events@3.3.0: {} - exact-mirror@0.2.2(@sinclair/typebox@0.34.41): optionalDependencies: '@sinclair/typebox': 0.34.41 - execa@8.0.1: - dependencies: - cross-spawn: 7.0.6 - get-stream: 8.0.1 - human-signals: 5.0.0 - is-stream: 3.0.0 - merge-stream: 2.0.0 - npm-run-path: 5.3.0 - onetime: 6.0.0 - signal-exit: 4.1.0 - strip-final-newline: 3.0.0 - exit-hook@2.2.1: {} expect-type@1.2.2: {} @@ -12324,22 +9339,10 @@ snapshots: extendable-error@0.1.7: {} - extract-zip@2.0.1: - dependencies: - debug: 4.4.3 - get-stream: 5.2.0 - yauzl: 2.10.0 - optionalDependencies: - '@types/yauzl': 2.10.3 - transitivePeerDependencies: - - supports-color - fast-decode-uri-component@1.0.1: {} fast-deep-equal@3.1.3: {} - fast-fifo@1.3.2: {} - fast-glob@3.3.3: dependencies: '@nodelib/fs.stat': 2.0.5 @@ -12364,8 +9367,6 @@ snapshots: dependencies: fast-decode-uri-component: 1.0.1 - fast-safe-stringify@2.1.1: {} - fast-uri@3.1.0: {} fastify-plugin@5.1.0: {} @@ -12398,29 +9399,14 @@ snapshots: dependencies: reusify: 1.1.0 - fd-slicer@1.1.0: - dependencies: - pend: 1.2.0 - fdir@6.5.0(picomatch@4.0.3): optionalDependencies: picomatch: 4.0.3 - fecha@4.2.3: {} - - fetch-blob@3.2.0: - dependencies: - node-domexception: 1.0.0 - web-streams-polyfill: 3.3.3 - fetchdts@0.1.7: {} fflate@0.8.2: {} - figures@6.1.0: - dependencies: - is-unicode-supported: 2.1.0 - file-type@21.0.0: dependencies: '@tokenizer/inflate': 0.2.7 @@ -12436,8 +9422,6 @@ snapshots: dependencies: to-regex-range: 5.0.1 - filter-obj@6.1.0: {} - finalhandler@2.1.0: dependencies: debug: 4.4.3 @@ -12455,21 +9439,11 @@ snapshots: fast-querystring: 1.1.2 safe-regex2: 5.0.0 - find-up-simple@1.0.1: {} - find-up@4.1.0: dependencies: locate-path: 5.0.0 path-exists: 4.0.0 - find-up@7.0.0: - dependencies: - locate-path: 7.2.0 - path-exists: 5.0.0 - unicorn-magic: 0.1.0 - - fn.name@1.1.0: {} - for-each@0.3.5: dependencies: is-callable: 1.2.7 @@ -12479,10 +9453,6 @@ snapshots: cross-spawn: 7.0.6 signal-exit: 4.1.0 - formdata-polyfill@4.0.10: - dependencies: - fetch-blob: 3.2.0 - forwarded@0.2.0: {} fresh@2.0.0: {} @@ -12522,13 +9492,6 @@ snapshots: gensync@1.0.0-beta.2: {} - get-amd-module-type@6.0.1: - dependencies: - ast-module-types: 6.0.1 - node-source-walk: 7.0.1 - - get-caller-file@2.0.5: {} - get-func-name@2.0.2: {} get-intrinsic@1.3.0: @@ -12544,8 +9507,6 @@ snapshots: hasown: 2.0.2 math-intrinsics: 1.1.0 - get-port-please@3.2.0: {} - get-port@7.1.0: {} get-proto@1.0.1: @@ -12553,12 +9514,6 @@ snapshots: dunder-proto: 1.0.1 es-object-atoms: 1.1.1 - get-stream@5.2.0: - dependencies: - pump: 3.0.3 - - get-stream@8.0.1: {} - get-symbol-description@1.1.0: dependencies: call-bound: 1.0.4 @@ -12606,10 +9561,6 @@ snapshots: globrex@0.1.2: {} - gonzales-pe@4.3.0: - dependencies: - minimist: 1.2.8 - goober@2.1.18(csstype@3.2.3): dependencies: csstype: 3.2.3 @@ -12634,15 +9585,13 @@ snapshots: dependencies: cookie-es: 2.0.0 fetchdts: 0.1.7 - rou3: 0.7.10 + rou3: 0.7.12 srvx: 0.8.16 optionalDependencies: crossws: 0.4.1(srvx@0.9.8) has-bigints@1.1.0: {} - has-flag@4.0.0: {} - has-property-descriptors@1.0.2: dependencies: es-define-property: 1.0.1 @@ -12746,10 +9695,6 @@ snapshots: hookable@5.5.3: {} - hosted-git-info@7.0.2: - dependencies: - lru-cache: 10.4.3 - html-encoding-sniffer@4.0.0: dependencies: whatwg-encoding: 3.1.1 @@ -12776,8 +9721,6 @@ snapshots: transitivePeerDependencies: - supports-color - http-shutdown@1.2.2: {} - https-proxy-agent@7.0.6: dependencies: agent-base: 7.1.4 @@ -12787,8 +9730,6 @@ snapshots: human-id@4.1.2: {} - human-signals@5.0.0: {} - iconv-lite@0.6.3: dependencies: safer-buffer: 2.1.2 @@ -12801,25 +9742,8 @@ snapshots: ignore@5.3.2: {} - image-meta@0.2.2: {} - - image-size@2.0.2: {} - - import-in-the-middle@1.15.0: - dependencies: - acorn: 8.15.0 - acorn-import-attributes: 1.9.5(acorn@8.15.0) - cjs-module-lexer: 1.2.3 - module-details-from-path: 1.0.4 - import-without-cache@0.2.4: {} - imurmurhash@0.1.4: {} - - indent-string@5.0.0: {} - - index-to-position@1.2.0: {} - inherits@2.0.4: {} inline-style-parser@0.2.4: {} @@ -12834,45 +9758,6 @@ snapshots: ipaddr.js@2.2.0: {} - ipx@3.1.1(@netlify/blobs@10.4.4): - dependencies: - '@fastify/accept-negotiator': 2.0.1 - citty: 0.1.6 - consola: 3.4.2 - defu: 6.1.4 - destr: 2.0.5 - etag: 1.8.1 - h3: 1.15.4 - image-meta: 0.2.2 - listhen: 1.9.0 - ofetch: 1.5.1 - pathe: 2.0.3 - sharp: 0.34.5 - svgo: 4.0.0 - ufo: 1.6.1 - unstorage: 1.17.3(@netlify/blobs@10.4.4) - xss: 1.0.15 - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@deno/kv' - - '@netlify/blobs' - - '@planetscale/database' - - '@upstash/redis' - - '@vercel/blob' - - '@vercel/functions' - - '@vercel/kv' - - aws4fetch - - db0 - - idb-keyval - - ioredis - - uploadthing - iron-webcrypto@1.2.1: {} is-alphabetical@2.0.1: {} @@ -12913,10 +9798,6 @@ snapshots: is-callable@1.2.7: {} - is-core-module@2.16.1: - dependencies: - hasown: 2.0.2 - is-data-view@1.0.2: dependencies: call-bound: 1.0.4 @@ -12930,8 +9811,6 @@ snapshots: is-decimal@2.0.1: {} - is-docker@3.0.0: {} - is-extglob@2.1.1: {} is-finalizationregistry@1.1.1: @@ -12954,16 +9833,10 @@ snapshots: is-hexadecimal@2.0.1: {} - is-inside-container@1.0.0: - dependencies: - is-docker: 3.0.0 - is-map@2.0.3: {} is-negative-zero@2.0.3: {} - is-network-error@1.3.0: {} - is-number-object@1.1.1: dependencies: call-bound: 1.0.4 @@ -12971,10 +9844,6 @@ snapshots: is-number@7.0.0: {} - is-path-inside@4.0.0: {} - - is-plain-obj@2.1.0: {} - is-plain-obj@4.1.0: {} is-potential-custom-element-name@1.0.1: {} @@ -12998,12 +9867,6 @@ snapshots: dependencies: call-bound: 1.0.4 - is-stream@2.0.1: {} - - is-stream@3.0.0: {} - - is-stream@4.0.1: {} - is-string@1.1.1: dependencies: call-bound: 1.0.4 @@ -13023,12 +9886,6 @@ snapshots: dependencies: which-typed-array: 1.1.19 - is-unicode-supported@2.1.0: {} - - is-url-superb@4.0.0: {} - - is-url@1.2.4: {} - is-weakmap@2.0.2: {} is-weakref@1.1.1: @@ -13042,16 +9899,6 @@ snapshots: is-windows@1.0.2: {} - is-wsl@3.1.0: - dependencies: - is-inside-container: 1.0.0 - - is64bit@2.0.0: - dependencies: - system-architecture: 0.1.0 - - isarray@1.0.0: {} - isarray@2.0.5: {} isbot@5.1.32: {} @@ -13068,12 +9915,6 @@ snapshots: jju@1.4.0: {} - jpeg-js@0.4.4: {} - - js-image-generator@1.0.4: - dependencies: - jpeg-js: 0.4.4 - js-tokens@4.0.0: {} js-tokens@9.0.1: {} @@ -13120,11 +9961,6 @@ snapshots: dependencies: dequal: 2.0.3 - json-schema-to-ts@1.6.4: - dependencies: - '@types/json-schema': 7.0.15 - ts-toolbelt: 6.15.5 - json-schema-traverse@0.4.1: optional: true @@ -13136,57 +9972,13 @@ snapshots: optionalDependencies: graceful-fs: 4.2.11 - jsonpointer@5.0.1: {} - - jsonwebtoken@9.0.2: - dependencies: - jws: 3.2.2 - lodash.includes: 4.3.0 - lodash.isboolean: 3.0.3 - lodash.isinteger: 4.0.4 - lodash.isnumber: 3.0.3 - lodash.isplainobject: 4.0.6 - lodash.isstring: 4.0.1 - lodash.once: 4.1.1 - ms: 2.1.3 - semver: 7.7.3 - - junk@4.0.1: {} - - jwa@1.4.2: - dependencies: - buffer-equal-constant-time: 1.0.1 - ecdsa-sig-formatter: 1.0.11 - safe-buffer: 5.2.1 - - jws@3.2.2: - dependencies: - jwa: 1.4.2 - safe-buffer: 5.2.1 - - jwt-decode@4.0.0: {} - kleur@4.1.5: {} - kuler@2.0.0: {} - - lambda-local@2.2.0: - dependencies: - commander: 10.0.1 - dotenv: 16.6.1 - winston: 3.18.3 - launch-editor@2.12.0: dependencies: picocolors: 1.1.1 shell-quote: 1.8.3 - lazystream@1.0.1: - dependencies: - readable-stream: 2.3.8 - - leven@3.1.0: {} - light-my-request@6.6.0: dependencies: cookie: 1.1.1 @@ -13242,62 +10034,12 @@ snapshots: lightningcss-win32-arm64-msvc: 1.30.2 lightningcss-win32-x64-msvc: 1.30.2 - listhen@1.9.0: - dependencies: - '@parcel/watcher': 2.5.1 - '@parcel/watcher-wasm': 2.5.1 - citty: 0.1.6 - clipboardy: 4.0.0 - consola: 3.4.2 - crossws: 0.3.5 - defu: 6.1.4 - get-port-please: 3.2.0 - h3: 1.15.4 - http-shutdown: 1.2.2 - jiti: 2.6.1 - mlly: 1.8.0 - node-forge: 1.3.2 - pathe: 1.1.2 - std-env: 3.10.0 - ufo: 1.6.1 - untun: 0.1.3 - uqr: 0.1.2 - locate-path@5.0.0: dependencies: p-locate: 4.1.0 - locate-path@7.2.0: - dependencies: - p-locate: 6.0.0 - - lodash.includes@4.3.0: {} - - lodash.isboolean@3.0.3: {} - - lodash.isinteger@4.0.4: {} - - lodash.isnumber@3.0.3: {} - - lodash.isplainobject@4.0.6: {} - - lodash.isstring@4.0.1: {} - - lodash.once@4.1.1: {} - lodash.startcase@4.4.0: {} - lodash@4.17.21: {} - - logform@2.7.0: - dependencies: - '@colors/colors': 1.6.0 - '@types/triple-beam': 1.3.5 - fecha: 4.2.3 - ms: 2.1.3 - safe-stable-stringify: 2.5.0 - triple-beam: 1.4.1 - longest-streak@3.1.0: {} loupe@2.3.7: @@ -13322,8 +10064,6 @@ snapshots: dependencies: react: 19.2.3 - luxon@3.7.2: {} - lz-string@1.5.0: {} magic-string@0.30.21: @@ -13336,10 +10076,6 @@ snapshots: '@babel/types': 7.28.5 source-map-js: 1.2.1 - make-error@1.3.6: {} - - map-obj@5.0.2: {} - markdown-extensions@2.0.0: {} markdown-table@3.0.4: {} @@ -13509,8 +10245,6 @@ snapshots: dependencies: '@types/mdast': 4.0.4 - mdn-data@2.0.28: {} - mdn-data@2.12.2: {} media-typer@1.1.0: {} @@ -13519,12 +10253,6 @@ snapshots: merge-descriptors@2.0.0: {} - merge-options@3.0.4: - dependencies: - is-plain-obj: 2.1.0 - - merge-stream@2.0.0: {} - merge2@1.4.1: {} micromark-core-commonmark@2.0.3: @@ -13796,13 +10524,7 @@ snapshots: braces: 3.0.3 picomatch: 2.3.1 - mime-db@1.52.0: {} - - mime-db@1.54.0: {} - - mime-types@2.1.35: - dependencies: - mime-db: 1.52.0 + mime-db@1.54.0: {} mime-types@3.0.1: dependencies: @@ -13810,8 +10532,6 @@ snapshots: mime@3.0.0: {} - mimic-fn@4.0.0: {} - miniflare@4.20251217.0: dependencies: '@cspotcode/source-map-support': 0.8.1 @@ -13834,42 +10554,16 @@ snapshots: dependencies: '@isaacs/brace-expansion': 5.0.0 - minimatch@3.1.2: - dependencies: - brace-expansion: 1.1.12 - - minimatch@5.1.6: - dependencies: - brace-expansion: 2.0.2 - minimatch@9.0.5: dependencies: brace-expansion: 2.0.2 - minimist@1.2.8: {} - minipass@7.1.2: {} minizlib@3.1.0: dependencies: minipass: 7.1.2 - mkdirp@1.0.4: {} - - mlly@1.8.0: - dependencies: - acorn: 8.15.0 - pathe: 2.0.3 - pkg-types: 1.3.1 - ufo: 1.6.1 - - module-definition@6.0.1: - dependencies: - ast-module-types: 6.0.1 - node-source-walk: 7.0.1 - - module-details-from-path@1.0.4: {} - mri@1.2.0: {} mrmime@2.0.1: {} @@ -13880,62 +10574,22 @@ snapshots: negotiator@1.0.0: {} - netlify-redirector@0.5.0: {} - - node-addon-api@7.1.1: {} - - node-domexception@1.0.0: {} - - node-fetch-native@1.6.7: {} - - node-fetch@2.6.9: - dependencies: - whatwg-url: 5.0.0 - node-fetch@2.7.0: dependencies: whatwg-url: 5.0.0 - node-fetch@3.3.2: - dependencies: - data-uri-to-buffer: 4.0.1 - fetch-blob: 3.2.0 - formdata-polyfill: 4.0.10 - - node-forge@1.3.2: {} - node-gyp-build@4.8.4: {} node-mock-http@1.0.3: {} node-releases@2.0.26: {} - node-source-walk@7.0.1: - dependencies: - '@babel/parser': 7.28.5 - - node-stream-zip@1.15.0: {} - nopt@8.1.0: dependencies: abbrev: 3.0.1 - normalize-package-data@6.0.2: - dependencies: - hosted-git-info: 7.0.2 - semver: 7.7.3 - validate-npm-package-license: 3.0.4 - - normalize-path@2.1.1: - dependencies: - remove-trailing-separator: 1.1.0 - normalize-path@3.0.0: {} - npm-run-path@5.3.0: - dependencies: - path-key: 4.0.0 - nth-check@2.1.1: dependencies: boolbase: 1.0.0 @@ -13955,14 +10609,6 @@ snapshots: obug@2.1.1: {} - ofetch@1.5.1: - dependencies: - destr: 2.0.5 - node-fetch-native: 1.6.7 - ufo: 1.6.1 - - omit.js@2.0.2: {} - on-exit-leak-free@2.1.2: {} on-finished@2.4.1: @@ -13973,14 +10619,6 @@ snapshots: dependencies: wrappy: 1.0.2 - one-time@1.0.0: - dependencies: - fn.name: 1.1.0 - - onetime@6.0.0: - dependencies: - mimic-fn: 4.0.0 - openapi-types@12.1.3: {} outdent@0.5.0: {} @@ -13991,10 +10629,6 @@ snapshots: object-keys: 1.1.1 safe-push-apply: 1.0.0 - p-event@6.0.1: - dependencies: - p-timeout: 6.1.4 - p-filter@2.1.0: dependencies: p-map: 2.1.0 @@ -14003,36 +10637,14 @@ snapshots: dependencies: p-try: 2.2.0 - p-limit@4.0.0: - dependencies: - yocto-queue: 1.2.2 - p-locate@4.1.0: dependencies: p-limit: 2.3.0 - p-locate@6.0.0: - dependencies: - p-limit: 4.0.0 - p-map@2.1.0: {} - p-map@7.0.4: {} - - p-retry@6.2.1: - dependencies: - '@types/retry': 0.12.2 - is-network-error: 1.3.0 - retry: 0.13.1 - - p-timeout@6.1.4: {} - p-try@2.2.0: {} - p-wait-for@5.0.2: - dependencies: - p-timeout: 6.1.4 - package-json-from-dist@1.0.1: {} package-manager-detector@0.2.11: @@ -14049,21 +10661,6 @@ snapshots: is-decimal: 2.0.1 is-hexadecimal: 2.0.1 - parse-gitignore@2.0.0: {} - - parse-imports@2.2.1: - dependencies: - es-module-lexer: 1.7.0 - slashes: 3.0.12 - - parse-json@8.3.0: - dependencies: - '@babel/code-frame': 7.27.1 - index-to-position: 1.2.0 - type-fest: 4.41.0 - - parse-ms@2.1.0: {} - parse-numeric-range@1.3.0: {} parse5-htmlparser2-tree-adapter@7.1.0: @@ -14085,18 +10682,10 @@ snapshots: parseurl@1.3.3: {} - path-browserify@1.0.1: {} - path-exists@4.0.0: {} - path-exists@5.0.0: {} - path-key@3.1.1: {} - path-key@4.0.0: {} - - path-parse@1.0.7: {} - path-scurry@1.11.1: dependencies: lru-cache: 10.4.3 @@ -14115,34 +10704,24 @@ snapshots: path-type@4.0.0: {} - path-type@6.0.0: {} - - pathe@1.1.2: {} - pathe@2.0.3: {} pathval@1.1.1: {} pathval@2.0.1: {} - pend@1.2.0: {} - periscopic@3.1.0: dependencies: '@types/estree': 1.0.8 estree-walker: 3.0.3 is-reference: 3.0.3 - picocolors@1.0.0: {} - picocolors@1.1.1: {} picomatch@2.3.1: {} picomatch@4.0.3: {} - picoquery@2.5.0: {} - pify@4.0.1: {} pino-abstract-transport@2.0.0: @@ -14169,12 +10748,6 @@ snapshots: dependencies: pngjs: 6.0.0 - pkg-types@1.3.1: - dependencies: - confbox: 0.1.8 - mlly: 1.8.0 - pathe: 2.0.3 - pkg-types@2.3.0: dependencies: confbox: 0.2.2 @@ -14199,39 +10772,12 @@ snapshots: possible-typed-array-names@1.1.0: {} - postcss-values-parser@6.0.2(postcss@8.5.6): - dependencies: - color-name: 1.1.4 - is-url-superb: 4.0.0 - postcss: 8.5.6 - quote-unquote: 1.0.0 - postcss@8.5.6: dependencies: nanoid: 3.3.11 picocolors: 1.1.1 source-map-js: 1.2.1 - precinct@12.2.0: - dependencies: - '@dependents/detective-less': 5.0.1 - commander: 12.1.0 - detective-amd: 6.0.1 - detective-cjs: 6.0.1 - detective-es6: 5.0.1 - detective-postcss: 7.0.1(postcss@8.5.6) - detective-sass: 6.0.1 - detective-scss: 5.0.1 - detective-stylus: 5.0.1 - detective-typescript: 14.0.0(typescript@5.9.3) - detective-vue2: 2.2.0(typescript@5.9.3) - module-definition: 6.0.1 - node-source-walk: 7.0.1 - postcss: 8.5.6 - typescript: 5.9.3 - transitivePeerDependencies: - - supports-color - prettier@2.8.8: {} prettier@3.6.2: {} @@ -14242,18 +10788,10 @@ snapshots: ansi-styles: 5.2.0 react-is: 17.0.2 - pretty-ms@7.0.1: - dependencies: - parse-ms: 2.1.0 - - process-nextick-args@2.0.1: {} - process-warning@4.0.1: {} process-warning@5.0.0: {} - process@0.11.10: {} - property-information@7.1.0: {} proxy-addr@2.0.7: @@ -14261,11 +10799,6 @@ snapshots: forwarded: 0.2.0 ipaddr.js: 1.9.1 - pump@3.0.3: - dependencies: - end-of-stream: 1.4.5 - once: 1.4.0 - punycode@2.3.1: {} qs@6.14.0: @@ -14280,8 +10813,6 @@ snapshots: quick-format-unescaped@4.0.4: {} - quote-unquote@1.0.0: {} - radix3@1.1.2: {} range-parser@1.2.1: {} @@ -14304,20 +10835,6 @@ snapshots: react@19.2.3: {} - read-package-up@11.0.0: - dependencies: - find-up-simple: 1.0.1 - read-pkg: 9.0.1 - type-fest: 4.41.0 - - read-pkg@9.0.1: - dependencies: - '@types/normalize-package-data': 2.4.4 - normalize-package-data: 6.0.2 - parse-json: 8.3.0 - type-fest: 4.41.0 - unicorn-magic: 0.1.0 - read-yaml-file@1.1.0: dependencies: graceful-fs: 4.2.11 @@ -14325,40 +10842,10 @@ snapshots: pify: 4.0.1 strip-bom: 3.0.0 - readable-stream@2.3.8: - dependencies: - core-util-is: 1.0.3 - inherits: 2.0.4 - isarray: 1.0.0 - process-nextick-args: 2.0.1 - safe-buffer: 5.1.2 - string_decoder: 1.1.1 - util-deprecate: 1.0.2 - - readable-stream@3.6.2: - dependencies: - inherits: 2.0.4 - string_decoder: 1.3.0 - util-deprecate: 1.0.2 - - readable-stream@4.7.0: - dependencies: - abort-controller: 3.0.0 - buffer: 6.0.3 - events: 3.3.0 - process: 0.11.10 - string_decoder: 1.3.0 - - readdir-glob@1.1.3: - dependencies: - minimatch: 5.1.6 - readdirp@3.6.0: dependencies: picomatch: 2.3.1 - readdirp@4.1.2: {} - real-require@0.2.0: {} recast@0.23.11: @@ -14448,42 +10935,14 @@ snapshots: mdast-util-to-markdown: 2.1.2 unified: 11.0.5 - remove-trailing-separator@1.1.0: {} - - require-directory@2.1.1: {} - require-from-string@2.0.2: {} - require-in-the-middle@7.5.2: - dependencies: - debug: 4.4.3 - module-details-from-path: 1.0.4 - resolve: 1.22.11 - transitivePeerDependencies: - - supports-color - - require-package-name@2.0.1: {} - resolve-from@5.0.0: {} resolve-pkg-maps@1.0.0: {} - resolve@1.22.11: - dependencies: - is-core-module: 2.16.1 - path-parse: 1.0.7 - supports-preserve-symlinks-flag: 1.0.0 - - resolve@2.0.0-next.5: - dependencies: - is-core-module: 2.16.1 - path-parse: 1.0.7 - supports-preserve-symlinks-flag: 1.0.0 - ret@0.5.0: {} - retry@0.13.1: {} - reusify@1.1.0: {} rfdc@1.4.1: {} @@ -14571,7 +11030,7 @@ snapshots: '@rollup/rollup-win32-x64-msvc': 4.53.5 fsevents: 2.3.3 - rou3@0.7.10: {} + rou3@0.7.12: {} router@2.2.0: dependencies: @@ -14595,8 +11054,6 @@ snapshots: has-symbols: 1.1.0 isarray: 2.0.5 - safe-buffer@5.1.2: {} - safe-buffer@5.2.1: {} safe-push-apply@1.0.0: @@ -14618,8 +11075,6 @@ snapshots: safer-buffer@2.1.2: {} - sax@1.4.3: {} - saxes@6.0.0: dependencies: xmlchars: 2.2.0 @@ -14725,37 +11180,6 @@ snapshots: '@img/sharp-win32-ia32': 0.33.5 '@img/sharp-win32-x64': 0.33.5 - sharp@0.34.5: - dependencies: - '@img/colour': 1.0.0 - detect-libc: 2.1.2 - semver: 7.7.3 - optionalDependencies: - '@img/sharp-darwin-arm64': 0.34.5 - '@img/sharp-darwin-x64': 0.34.5 - '@img/sharp-libvips-darwin-arm64': 1.2.4 - '@img/sharp-libvips-darwin-x64': 1.2.4 - '@img/sharp-libvips-linux-arm': 1.2.4 - '@img/sharp-libvips-linux-arm64': 1.2.4 - '@img/sharp-libvips-linux-ppc64': 1.2.4 - '@img/sharp-libvips-linux-riscv64': 1.2.4 - '@img/sharp-libvips-linux-s390x': 1.2.4 - '@img/sharp-libvips-linux-x64': 1.2.4 - '@img/sharp-libvips-linuxmusl-arm64': 1.2.4 - '@img/sharp-libvips-linuxmusl-x64': 1.2.4 - '@img/sharp-linux-arm': 0.34.5 - '@img/sharp-linux-arm64': 0.34.5 - '@img/sharp-linux-ppc64': 0.34.5 - '@img/sharp-linux-riscv64': 0.34.5 - '@img/sharp-linux-s390x': 0.34.5 - '@img/sharp-linux-x64': 0.34.5 - '@img/sharp-linuxmusl-arm64': 0.34.5 - '@img/sharp-linuxmusl-x64': 0.34.5 - '@img/sharp-wasm32': 0.34.5 - '@img/sharp-win32-arm64': 0.34.5 - '@img/sharp-win32-ia32': 0.34.5 - '@img/sharp-win32-x64': 0.34.5 - shebang-command@2.0.0: dependencies: shebang-regex: 3.0.0 @@ -14798,8 +11222,6 @@ snapshots: siginfo@2.0.0: {} - signal-exit@4.0.2: {} - signal-exit@4.1.0: {} simple-swizzle@0.2.4: @@ -14814,8 +11236,6 @@ snapshots: slash@3.0.0: {} - slashes@3.0.12: {} - solid-js@1.9.10: dependencies: csstype: 3.2.3 @@ -14844,20 +11264,6 @@ snapshots: cross-spawn: 7.0.6 signal-exit: 4.1.0 - spdx-correct@3.2.0: - dependencies: - spdx-expression-parse: 3.0.1 - spdx-license-ids: 3.0.22 - - spdx-exceptions@2.5.0: {} - - spdx-expression-parse@3.0.1: - dependencies: - spdx-exceptions: 2.5.0 - spdx-license-ids: 3.0.22 - - spdx-license-ids@3.0.22: {} - split2@4.2.0: {} sprintf-js@1.0.3: {} @@ -14866,8 +11272,6 @@ snapshots: srvx@0.9.8: {} - stack-trace@0.0.10: {} - stackback@0.0.2: {} standaloner@0.1.11(rollup@4.53.5): @@ -14895,15 +11299,6 @@ snapshots: stoppable@1.1.0: {} - streamx@2.23.0: - dependencies: - events-universal: 1.0.1 - fast-fifo: 1.3.2 - text-decoder: 1.2.3 - transitivePeerDependencies: - - bare-abort-controller - - react-native-b4a - string-width@4.2.3: dependencies: emoji-regex: 8.0.0 @@ -14950,14 +11345,6 @@ snapshots: define-properties: 1.2.1 es-object-atoms: 1.1.1 - string_decoder@1.1.1: - dependencies: - safe-buffer: 5.1.2 - - string_decoder@1.3.0: - dependencies: - safe-buffer: 5.2.1 - stringify-entities@4.0.4: dependencies: character-entities-html4: 2.1.0 @@ -14973,8 +11360,6 @@ snapshots: strip-bom@3.0.0: {} - strip-final-newline@3.0.0: {} - strip-literal@3.1.0: dependencies: js-tokens: 9.0.1 @@ -14993,39 +11378,12 @@ snapshots: supports-color@10.2.2: {} - supports-color@7.2.0: - dependencies: - has-flag: 4.0.0 - - supports-preserve-symlinks-flag@1.0.0: {} - - svgo@4.0.0: - dependencies: - commander: 11.1.0 - css-select: 5.2.2 - css-tree: 3.1.0 - css-what: 6.2.2 - csso: 5.0.5 - picocolors: 1.1.1 - sax: 1.4.3 - symbol-tree@3.2.4: {} - system-architecture@0.1.0: {} - tailwindcss@4.1.17: {} tapable@2.3.0: {} - tar-stream@3.1.7: - dependencies: - b4a: 1.7.3 - fast-fifo: 1.3.2 - streamx: 2.23.0 - transitivePeerDependencies: - - bare-abort-controller - - react-native-b4a - tar@7.5.1: dependencies: '@isaacs/fs-minipass': 4.0.1 @@ -15036,22 +11394,10 @@ snapshots: term-size@2.2.1: {} - text-decoder@1.2.3: - dependencies: - b4a: 1.7.3 - transitivePeerDependencies: - - react-native-b4a - - text-hex@1.0.0: {} - thread-stream@3.1.0: dependencies: real-require: 0.2.0 - time-span@4.0.0: - dependencies: - convert-hrtime: 3.0.0 - tiny-invariant@1.3.3: {} tiny-warning@1.0.3: {} @@ -15079,12 +11425,6 @@ snapshots: dependencies: tldts-core: 7.0.17 - tmp-promise@3.0.3: - dependencies: - tmp: 0.2.5 - - tmp@0.2.5: {} - to-regex-range@5.0.1: dependencies: is-number: 7.0.0 @@ -15099,10 +11439,6 @@ snapshots: '@tokenizer/token': 0.3.0 ieee754: 1.2.1 - toml@3.0.0: {} - - tomlify-j0.4@3.0.0: {} - totalist@3.0.1: {} tough-cookie@6.0.0: @@ -15119,43 +11455,10 @@ snapshots: trim-lines@3.0.1: {} - triple-beam@1.4.1: {} - trough@2.2.0: {} - ts-api-utils@2.1.0(typescript@5.9.3): - dependencies: - typescript: 5.9.3 - ts-deepmerge@7.0.3: {} - ts-morph@12.0.0: - dependencies: - '@ts-morph/common': 0.11.1 - code-block-writer: 10.1.1 - - ts-node@10.9.1(@swc/core@1.13.5)(@types/node@16.18.11)(typescript@4.9.5): - dependencies: - '@cspotcode/source-map-support': 0.8.1 - '@tsconfig/node10': 1.0.11 - '@tsconfig/node12': 1.0.11 - '@tsconfig/node14': 1.0.3 - '@tsconfig/node16': 1.0.4 - '@types/node': 16.18.11 - acorn: 8.15.0 - acorn-walk: 8.3.4 - arg: 4.1.3 - create-require: 1.1.1 - diff: 4.0.2 - make-error: 1.3.6 - typescript: 4.9.5 - v8-compile-cache-lib: 3.0.1 - yn: 3.1.1 - optionalDependencies: - '@swc/core': 1.13.5 - - ts-toolbelt@6.15.5: {} - tsconfck@3.1.6(typescript@5.9.3): optionalDependencies: typescript: 5.9.3 @@ -15198,8 +11501,6 @@ snapshots: type-detect@4.1.0: {} - type-fest@4.41.0: {} - type-is@2.0.1: dependencies: content-type: 1.0.5 @@ -15239,16 +11540,12 @@ snapshots: possible-typed-array-names: 1.1.0 reflect.getprototypeof: 1.0.10 - typescript@4.9.5: {} - typescript@5.9.3: {} ufo@1.6.1: {} uint8array-extras@1.5.0: {} - ulid@3.0.2: {} - unbox-primitive@1.1.0: dependencies: call-bound: 1.0.4 @@ -15265,18 +11562,12 @@ snapshots: undici-types@6.21.0: {} - undici@5.28.4: - dependencies: - '@fastify/busboy': 2.1.1 - undici@7.14.0: {} unenv@2.0.0-rc.24: dependencies: pathe: 2.0.3 - unicorn-magic@0.1.0: {} - unified@11.0.5: dependencies: '@types/unist': 3.0.3 @@ -15316,10 +11607,6 @@ snapshots: universalify@0.1.2: {} - unixify@1.0.0: - dependencies: - normalize-path: 2.1.1 - unpipe@1.0.0: {} unplugin@2.3.11: @@ -15333,60 +11620,21 @@ snapshots: dependencies: rolldown: 1.0.0-beta.55 - unstorage@1.17.3(@netlify/blobs@10.4.4): - dependencies: - anymatch: 3.1.3 - chokidar: 4.0.3 - destr: 2.0.5 - h3: 1.15.4 - lru-cache: 10.4.3 - node-fetch-native: 1.6.7 - ofetch: 1.5.1 - ufo: 1.6.1 - optionalDependencies: - '@netlify/blobs': 10.4.4 - - untun@0.1.3: - dependencies: - citty: 0.1.6 - consola: 3.4.2 - pathe: 1.1.2 - update-browserslist-db@1.1.3(browserslist@4.26.3): dependencies: browserslist: 4.26.3 escalade: 3.2.0 picocolors: 1.1.1 - uqr@0.1.2: {} - uri-js@4.4.1: dependencies: punycode: 2.3.1 - - urlpattern-polyfill@10.1.0: {} - - urlpattern-polyfill@8.0.2: {} + optional: true use-sync-external-store@1.6.0(react@19.2.3): dependencies: react: 19.2.3 - util-deprecate@1.0.2: {} - - uuid@11.1.0: {} - - uuid@13.0.0: {} - - v8-compile-cache-lib@3.0.1: {} - - validate-npm-package-license@3.0.4: - dependencies: - spdx-correct: 3.2.0 - spdx-expression-parse: 3.0.1 - - validate-npm-package-name@5.0.1: {} - vary@1.1.2: {} vfile-location@5.0.3: @@ -15446,9 +11694,9 @@ snapshots: - tsx - yaml - vite-plugin-wasm@3.5.0(vite@7.2.4(@types/node@20.19.25)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): + vite-plugin-wasm@3.5.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): dependencies: - vite: 7.2.4(@types/node@20.19.25)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) vite-tsconfig-paths@5.1.4(typescript@5.9.3)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): dependencies: @@ -15461,22 +11709,6 @@ snapshots: - supports-color - typescript - vite@7.2.4(@types/node@20.19.25)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2): - dependencies: - esbuild: 0.25.12 - fdir: 6.5.0(picomatch@4.0.3) - picomatch: 4.0.3 - postcss: 8.5.6 - rollup: 4.53.5 - tinyglobby: 0.2.15 - optionalDependencies: - '@types/node': 20.19.25 - fsevents: 2.3.3 - jiti: 2.6.1 - lightningcss: 1.30.2 - tsx: 4.20.6 - yaml: 2.8.2 - vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2): dependencies: esbuild: 0.25.12 @@ -15547,8 +11779,6 @@ snapshots: web-namespaces@2.0.1: {} - web-streams-polyfill@3.3.3: {} - web-vitals@5.1.0: {} webidl-conversions@3.0.1: {} @@ -15623,26 +11853,6 @@ snapshots: siginfo: 2.0.0 stackback: 0.0.2 - winston-transport@4.9.0: - dependencies: - logform: 2.7.0 - readable-stream: 3.6.2 - triple-beam: 1.4.1 - - winston@3.18.3: - dependencies: - '@colors/colors': 1.6.0 - '@dabh/diagnostics': 2.0.8 - async: 3.2.6 - is-stream: 2.0.1 - logform: 2.7.0 - one-time: 1.0.0 - readable-stream: 3.6.2 - safe-stable-stringify: 2.5.0 - stack-trace: 0.0.10 - triple-beam: 1.4.1 - winston-transport: 4.9.0 - workerd@1.20251217.0: optionalDependencies: '@cloudflare/workerd-darwin-64': 1.20251217.0 @@ -15682,11 +11892,6 @@ snapshots: wrappy@1.0.2: {} - write-file-atomic@5.0.1: - dependencies: - imurmurhash: 0.1.4 - signal-exit: 4.1.0 - ws@8.18.0: {} ws@8.18.3: {} @@ -15702,41 +11907,14 @@ snapshots: xmlchars@2.2.0: {} - xss@1.0.15: - dependencies: - commander: 2.20.3 - cssfilter: 0.0.10 - - y18n@5.0.8: {} - yallist@3.1.1: {} yallist@4.0.0: {} yallist@5.0.0: {} - yaml@2.8.2: {} - - yargs-parser@21.1.1: {} - - yargs@17.7.2: - dependencies: - cliui: 8.0.1 - escalade: 3.2.0 - get-caller-file: 2.0.5 - require-directory: 2.1.1 - string-width: 4.2.3 - y18n: 5.0.8 - yargs-parser: 21.1.1 - - yauzl@2.10.0: - dependencies: - buffer-crc32: 0.2.13 - fd-slicer: 1.1.0 - - yn@3.1.1: {} - - yocto-queue@1.2.2: {} + yaml@2.8.2: + optional: true youch-core@0.3.3: dependencies: @@ -15751,12 +11929,6 @@ snapshots: cookie: 1.1.1 youch-core: 0.3.3 - zip-stream@6.0.1: - dependencies: - archiver-utils: 5.0.2 - compress-commons: 6.0.2 - readable-stream: 4.7.0 - zod@3.22.3: {} zod@3.25.76: {} diff --git a/tests/app/hmr-route.ts b/tests/app/hmr-route.ts index 953d5e3e..7c99de12 100644 --- a/tests/app/hmr-route.ts +++ b/tests/app/hmr-route.ts @@ -1,14 +1,7 @@ -import { enhance } from "@universal-middleware/core"; - -export const hmrRoute = enhance( - async () => { +export default { + fetch() { return new Response("BEFORE HMR", { status: 200, }); }, - { - name: "photon-test:hmr", - path: "/hmr", - method: "GET", - }, -); +}; diff --git a/tests/app/hono-entry.ts b/tests/app/hono-entry.ts index e0a38848..da070e48 100644 --- a/tests/app/hono-entry.ts +++ b/tests/app/hono-entry.ts @@ -1,16 +1,12 @@ import { apply, serve } from "@photonjs/hono"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; import { Hono } from "hono"; -import { hmrRoute } from "./hmr-route.js"; function startServer() { const app = new Hono(); - // Auto applies `awesomeFramework` - apply( - app, - // HMR route - [hmrRoute], - ); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); return serve(app); } diff --git a/tests/app/package.json b/tests/app/package.json index 08b4b821..faf0dded 100644 --- a/tests/app/package.json +++ b/tests/app/package.json @@ -10,7 +10,6 @@ "test:types": "tsc --noEmit" }, "devDependencies": { - "@photonjs/cloudflare": "workspace:0.1.13", "@photonjs/core": "workspace:0.1.21", "@photonjs/elysia": "workspace:0.1.12", "@photonjs/express": "workspace:0.1.13", @@ -20,9 +19,9 @@ "@photonjs/hono": "workspace:0.1.12", "@photonjs/runtime": "workspace:0.1.16", "@photonjs/srvx": "workspace:0.1.12", - "@photonjs/vercel": "workspace:0.1.22", "@types/express": "^5.0.6", "@types/node": "^22.19.1", + "@universal-deploy/store": "^0.0.2", "@universal-middleware/core": "^0.4.14", "pkg-types": "^2.3.0", "typescript": "^5.9.3", diff --git a/tests/app/vite.config.ts b/tests/app/vite.config.ts index f9e4dc0d..a1729af6 100644 --- a/tests/app/vite.config.ts +++ b/tests/app/vite.config.ts @@ -1,29 +1,26 @@ -/// -/* The Vite plugin cloudflare() will be replaced by this: -import cloudflare from '@photonjs/cloudflare' -*/ -import { cloudflare } from "@photonjs/cloudflare/vite"; -import { vercel } from "@photonjs/vercel/vite"; +// import { cloudflare } from "@photonjs/cloudflare/vite"; +// import { vercel } from "@photonjs/vercel/vite"; +import { store } from "@universal-deploy/store"; import { awesomeFramework } from "awesome-framework/vite"; import { defineConfig } from "vite"; const target = process.env.TARGET ?? "node"; const server = process.env.SERVER ?? "hono"; +store.entries.push({ + id: "./hmr-route.ts", + method: "GET", + pattern: "/hmr", +}); + export default defineConfig({ - photon: { - server: `${server}-entry.ts`, - /* The Vite plugin cloudflare() will be replaced by this: - target: cloudflare, // not needed when using @photonjs/auto - */ - }, plugins: [ - // Will be replaced with a photon.target setting - target === "cloudflare" && - cloudflare({ - inspectorPort: false, - }), // not needed when using @photonjs/auto - target === "vercel" && vercel(), + // // Will be replaced with a photon.target setting + // target === "cloudflare" && + // cloudflare({ + // inspectorPort: false, + // }), // not needed when using @photonjs/auto + // target === "vercel" && vercel(), awesomeFramework(), ], build: { From a4288ae40172fe3c3334a2ee137726a179986cbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Wed, 21 Jan 2026 13:44:19 +0100 Subject: [PATCH 03/62] wip --- tests/app/elysia-entry.ts | 19 ++++++++++++------- tests/app/express-entry.ts | 14 +++++++------- tests/app/fastify-entry.ts | 14 +++++++------- tests/app/fetch-entry.ts | 9 +++------ tests/app/h3-entry.ts | 21 ++++++++++++--------- tests/app/hattip-entry.ts | 19 ++++++++++++------- tests/app/hono-entry.ts | 9 +++++++++ tests/app/srvx-entry.ts | 9 +++------ 8 files changed, 65 insertions(+), 49 deletions(-) diff --git a/tests/app/elysia-entry.ts b/tests/app/elysia-entry.ts index f13f05e4..962a29b4 100644 --- a/tests/app/elysia-entry.ts +++ b/tests/app/elysia-entry.ts @@ -1,16 +1,21 @@ import { apply, serve } from "@photonjs/elysia"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; import { Elysia } from "elysia"; -import { hmrRoute } from "./hmr-route.js"; function startServer() { const app = new Elysia(); - // Auto applies `awesomeFramework` - apply( - app, - // HMR route - [hmrRoute], - ); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + + app.get("/serverid", () => { + return new Response("elysia", { + status: 200, + headers: { + "Content-Type": "text/plain", + }, + }); + }); return serve(app); } diff --git a/tests/app/express-entry.ts b/tests/app/express-entry.ts index 38d99e59..41958aae 100644 --- a/tests/app/express-entry.ts +++ b/tests/app/express-entry.ts @@ -1,17 +1,17 @@ import type { ServeReturn } from "@photonjs/core/serve"; import { apply, serve } from "@photonjs/express"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; import express, { type Express } from "express"; -import { hmrRoute } from "./hmr-route.js"; function startServer(): ServeReturn { const app = express(); - // Auto applies `awesomeFramework` - apply( - app, - // HMR route - [hmrRoute], - ); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + + app.get("/serverid", (_, res) => { + res.status(200).send("express"); + }); return serve(app); } diff --git a/tests/app/fastify-entry.ts b/tests/app/fastify-entry.ts index cdd2c2f8..8465b9ac 100644 --- a/tests/app/fastify-entry.ts +++ b/tests/app/fastify-entry.ts @@ -1,7 +1,8 @@ import type { ServeReturn } from "@photonjs/core/serve"; import { apply, serve } from "@photonjs/fastify"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; import fastify, { type FastifyInstance } from "fastify"; -import { hmrRoute } from "./hmr-route.js"; async function startServer(): Promise> { const app = fastify({ @@ -9,12 +10,11 @@ async function startServer(): Promise> { forceCloseConnections: true, }); - // Auto applies `awesomeFramework` - await apply( - app, - // HMR route - [hmrRoute], - ); + await apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + + app.get("/serverid", (_, reply) => { + reply.send("fastify"); + }); return serve(app); } diff --git a/tests/app/fetch-entry.ts b/tests/app/fetch-entry.ts index 026c60fb..2690a3f5 100644 --- a/tests/app/fetch-entry.ts +++ b/tests/app/fetch-entry.ts @@ -1,11 +1,8 @@ import { apply } from "@photonjs/srvx"; -import { hmrRoute } from "./hmr-route.js"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; -// Auto applies `awesomeFramework` -const app = apply( - // HMR route - [hmrRoute], -); +const app = apply([...awesomeMiddlewares, awesomeEntry.fetch]); export default { fetch: app, diff --git a/tests/app/h3-entry.ts b/tests/app/h3-entry.ts index 9e0ff4d8..72f9abc1 100644 --- a/tests/app/h3-entry.ts +++ b/tests/app/h3-entry.ts @@ -1,18 +1,21 @@ import { apply, serve } from "@photonjs/h3"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; import { createApp } from "h3"; -import { hmrRoute } from "./hmr-route.js"; async function startServer() { const app = createApp(); - // Auto applies `awesomeFramework` - apply( - app, - // HMR route - [hmrRoute], - ); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + + app.use("/serverid", () => { + return new Response("h3", { + status: 200, + headers: { + "Content-Type": "text/plain", + }, + }); + }); return serve(app); } - -export default await startServer(); diff --git a/tests/app/hattip-entry.ts b/tests/app/hattip-entry.ts index 1f54797b..1469dfd4 100644 --- a/tests/app/hattip-entry.ts +++ b/tests/app/hattip-entry.ts @@ -1,16 +1,21 @@ import { createRouter } from "@hattip/router"; import { apply, serve } from "@photonjs/hattip"; -import { hmrRoute } from "./hmr-route.js"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; function startServer() { const app = createRouter(); - // Auto applies `awesomeFramework` - apply( - app, - // HMR route - [hmrRoute], - ); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + + app.get("/serverid", () => { + return new Response("hattip", { + status: 200, + headers: { + "Content-Type": "text/plain", + }, + }); + }); return serve(app); } diff --git a/tests/app/hono-entry.ts b/tests/app/hono-entry.ts index da070e48..a689069c 100644 --- a/tests/app/hono-entry.ts +++ b/tests/app/hono-entry.ts @@ -8,6 +8,15 @@ function startServer() { apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + app.get("/serverid", () => { + return new Response("hono", { + status: 200, + headers: { + "Content-Type": "text/plain", + }, + }); + }); + return serve(app); } diff --git a/tests/app/srvx-entry.ts b/tests/app/srvx-entry.ts index dc9d6501..01e1cb41 100644 --- a/tests/app/srvx-entry.ts +++ b/tests/app/srvx-entry.ts @@ -1,12 +1,9 @@ import { apply, serve } from "@photonjs/srvx"; -import { hmrRoute } from "./hmr-route.js"; +import awesomeMiddlewares from "awesome-framework/middlewares"; +import awesomeEntry from "awesome-framework/server-entry"; function startServer() { - // Auto applies `awesomeFramework` - const app = apply( - // HMR route - [hmrRoute], - ); + const app = apply([...awesomeMiddlewares, awesomeEntry.fetch]); return serve(app); } From 0d67044f27141ba07e43270ff3649f44a34eb346 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Wed, 21 Jan 2026 15:48:13 +0100 Subject: [PATCH 04/62] wip --- example/awesome-framework/package.json | 3 +- .../src/photon/entries/virtual.ts | 5 -- example/awesome-framework/virtual.d.ts | 6 -- packages/hono/src/apply-dev.ts | 12 +-- pnpm-lock.yaml | 79 +++++++++++++++++-- tests/app/elysia-entry.ts | 2 +- tests/app/express-entry.ts | 2 +- tests/app/fastify-entry.ts | 2 +- tests/app/fetch-entry.ts | 2 +- tests/app/h3-entry.ts | 2 +- tests/app/hattip-entry.ts | 2 +- tests/app/hono-entry.ts | 9 ++- tests/app/package.json | 3 +- tests/app/srvx-entry.ts | 2 +- tests/app/virtual.d.ts | 5 ++ tests/app/vite.config.ts | 16 ++++ 16 files changed, 111 insertions(+), 41 deletions(-) delete mode 100644 example/awesome-framework/src/photon/entries/virtual.ts create mode 100644 tests/app/virtual.d.ts diff --git a/example/awesome-framework/package.json b/example/awesome-framework/package.json index 08a7c9f2..d421ff5e 100644 --- a/example/awesome-framework/package.json +++ b/example/awesome-framework/package.json @@ -14,7 +14,7 @@ }, "devDependencies": { "@types/node": "^22.19.1", - "@universal-deploy/store": "^0.0.2", + "@universal-deploy/store": "^0.0.5", "typescript": "^5.9.3", "vite": "^7.2.4" }, @@ -25,7 +25,6 @@ "./vite": "./dist/vite/index.js", "./entries/api": "./dist/photon/entries/api.js", "./entries/ssr": "./dist/photon/entries/ssr.js", - "./server-entry": "./dist/photon/entries/virtual.js", "./middlewares": "./dist/photon/middlewares/index.js" } } diff --git a/example/awesome-framework/src/photon/entries/virtual.ts b/example/awesome-framework/src/photon/entries/virtual.ts deleted file mode 100644 index 1cba5834..00000000 --- a/example/awesome-framework/src/photon/entries/virtual.ts +++ /dev/null @@ -1,5 +0,0 @@ -import fetchable from "virtual:ud:catch-all"; - -export * from "virtual:ud:catch-all"; - -export default fetchable; diff --git a/example/awesome-framework/virtual.d.ts b/example/awesome-framework/virtual.d.ts index 04e8756d..e88a9e28 100644 --- a/example/awesome-framework/virtual.d.ts +++ b/example/awesome-framework/virtual.d.ts @@ -3,9 +3,3 @@ declare module "virtual:awesome-plugin:*" { const handler: any; export default handler; } - -declare module "virtual:ud:catch-all" { - export default { - fetch(request: Request): Response | Promise {}, - }; -} diff --git a/packages/hono/src/apply-dev.ts b/packages/hono/src/apply-dev.ts index c6e3dbd1..7add583a 100644 --- a/packages/hono/src/apply-dev.ts +++ b/packages/hono/src/apply-dev.ts @@ -1,20 +1,14 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:dev:hono"; -import type { Fetchable } from "@photonjs/core/api/internal"; import { createApply } from "@photonjs/core/apply"; import { devServerMiddleware } from "@photonjs/core/dev"; -import type { RuntimeAdapterTarget, UniversalMiddleware } from "@universal-middleware/core"; +import type { RuntimeAdapterTarget } from "@universal-middleware/core"; import { apply as applyAdapter } from "@universal-middleware/hono"; export const apply = createApply( "hono", applyAdapter, - getUniversalEntries, - getUniversalMiddlewares, + () => [], + () => [], devServerMiddleware, ); -function fetchableToUniversalMiddleware(entry: Fetchable): UniversalMiddleware { - return entry.fetch; -} - export type RuntimeAdapter = RuntimeAdapterTarget<"hono">; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e622bfd5..b61e1365 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -212,8 +212,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-deploy/store': - specifier: ^0.0.2 - version: 0.0.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.0.5 + version: 0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) typescript: specifier: ^5.9.3 version: 5.9.3 @@ -632,6 +632,9 @@ importers: '@hattip/router': specifier: ^0.0.49 version: 0.0.49 + '@universal-middleware/hono': + specifier: ^0.4.20 + version: 0.4.20(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 'workspace:' version: link:../../example/awesome-framework @@ -688,8 +691,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-deploy/store': - specifier: ^0.0.2 - version: 0.0.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.0.5 + version: 0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/core': specifier: ^0.4.14 version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -2981,8 +2984,8 @@ packages: '@ungap/structured-clone@1.3.0': resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} - '@universal-deploy/store@0.0.2': - resolution: {integrity: sha512-fmNALSCBkjrpJmidLmMU5c4jWTXs/CKsgk9cDmTPZpne5+vWLqw73Smav6NT2tXbkGlG9nl8v4BNIFb1eE9wuw==} + '@universal-deploy/store@0.0.5': + resolution: {integrity: sha512-+V6twaKK+vLhjKlXpI6wZ0Ijm0/4EVSpjA+uzT7XzFflYmtFHGFQB3LGjzWfUo9UGRRf7LYarN5H4zbW+0UXJw==} '@universal-middleware/cloudflare@0.4.10': resolution: {integrity: sha512-ZY+N0KKoH+H+BB3wsaD5yqTiiFtX7uklPyCBqGLqEijOtZA5ZgFIExfWDjiIUjezUBAbRB8kUZ/WlPITY+hyTg==} @@ -3022,6 +3025,38 @@ packages: srvx: optional: true + '@universal-middleware/core@0.4.15': + resolution: {integrity: sha512-4nUc79ANoExxldCGz4b2ttyxjopcmO8MH7sbJLCvFKxa9DdbHfsXI9+HAvgbKAYqC8FAFbadsMzqnAeSqis1dw==} + peerDependencies: + '@cloudflare/workers-types': ^4.20260114.0 + '@hattip/core': ^0.0.49 + '@types/express': ^4 || ^5 + '@webroute/route': ^0.8.0 + elysia: ^1.4.22 + fastify: ^5.6.2 + h3: ^1.15.4 + hono: ^4.11.4 + srvx: ^0.8 || ^0.9 + peerDependenciesMeta: + '@cloudflare/workers-types': + optional: true + '@hattip/core': + optional: true + '@types/express': + optional: true + '@webroute/route': + optional: true + elysia: + optional: true + fastify: + optional: true + h3: + optional: true + hono: + optional: true + srvx: + optional: true + '@universal-middleware/elysia@0.6.2': resolution: {integrity: sha512-2sYpGd07iHqiyezCtWX7JB36Cd33kIIaferkm/CiAlTqx/N5tjK0rg3ounY1BWnezcluqSe1lBQu8JztJ/dSWQ==} @@ -3040,6 +3075,9 @@ packages: '@universal-middleware/hono@0.4.18': resolution: {integrity: sha512-RpnX8hKh2zx7hwVYzI32DjvH7KBYpt7MLIHWYw9QBSEzpD1ErqL+SpkvvlJaINjFs+sYJKH5IOoL53uHCL5alw==} + '@universal-middleware/hono@0.4.20': + resolution: {integrity: sha512-UYsp/urka7BEilzAn/SlnDNxel5rWKV+hRDqwoPhq3E1bJ91M6YuT5OR4EtTm2Jx4S0fFMr8ITA2F4hWZ/+vgw==} + '@universal-middleware/sirv@0.1.24': resolution: {integrity: sha512-BshKQ6hsb3mbgIyFguyf6QEjqAFGW2KGLd3j/N1aK2b1bicD2elsWOD5UYSb0b84VHglGmISqOu30FbfMWhMgg==} @@ -8174,7 +8212,7 @@ snapshots: '@ungap/structured-clone@1.3.0': {} - '@universal-deploy/store@0.0.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-deploy/store@0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) rou3: 0.7.12 @@ -8219,6 +8257,19 @@ snapshots: hono: 4.11.1 srvx: 0.9.8 + '@universal-middleware/core@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + dependencies: + regexparam: 3.0.0 + tough-cookie: 6.0.0 + optionalDependencies: + '@hattip/core': 0.0.49 + '@types/express': 5.0.6 + elysia: 1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3) + fastify: 5.6.2 + h3: 1.15.4 + hono: 4.11.1 + srvx: 0.9.8 + '@universal-middleware/elysia@0.6.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -8305,6 +8356,20 @@ snapshots: - hono - srvx + '@universal-middleware/hono@0.4.20(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + dependencies: + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + transitivePeerDependencies: + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@webroute/route' + - elysia + - fastify + - h3 + - hono + - srvx + '@universal-middleware/sirv@0.1.24': dependencies: mrmime: 2.0.1 diff --git a/tests/app/elysia-entry.ts b/tests/app/elysia-entry.ts index 962a29b4..624c5a76 100644 --- a/tests/app/elysia-entry.ts +++ b/tests/app/elysia-entry.ts @@ -1,6 +1,6 @@ +import awesomeEntry from "virtual:ud:catch-all?default"; import { apply, serve } from "@photonjs/elysia"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; import { Elysia } from "elysia"; function startServer() { diff --git a/tests/app/express-entry.ts b/tests/app/express-entry.ts index 41958aae..8438d188 100644 --- a/tests/app/express-entry.ts +++ b/tests/app/express-entry.ts @@ -1,7 +1,7 @@ +import awesomeEntry from "virtual:ud:catch-all?default"; import type { ServeReturn } from "@photonjs/core/serve"; import { apply, serve } from "@photonjs/express"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; import express, { type Express } from "express"; function startServer(): ServeReturn { diff --git a/tests/app/fastify-entry.ts b/tests/app/fastify-entry.ts index 8465b9ac..6167f9cf 100644 --- a/tests/app/fastify-entry.ts +++ b/tests/app/fastify-entry.ts @@ -1,7 +1,7 @@ +import awesomeEntry from "virtual:ud:catch-all?default"; import type { ServeReturn } from "@photonjs/core/serve"; import { apply, serve } from "@photonjs/fastify"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; import fastify, { type FastifyInstance } from "fastify"; async function startServer(): Promise> { diff --git a/tests/app/fetch-entry.ts b/tests/app/fetch-entry.ts index 2690a3f5..f1e5bf83 100644 --- a/tests/app/fetch-entry.ts +++ b/tests/app/fetch-entry.ts @@ -1,6 +1,6 @@ +import awesomeEntry from "virtual:ud:catch-all?default"; import { apply } from "@photonjs/srvx"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; const app = apply([...awesomeMiddlewares, awesomeEntry.fetch]); diff --git a/tests/app/h3-entry.ts b/tests/app/h3-entry.ts index 72f9abc1..d16771cc 100644 --- a/tests/app/h3-entry.ts +++ b/tests/app/h3-entry.ts @@ -1,6 +1,6 @@ +import awesomeEntry from "virtual:ud:catch-all?default"; import { apply, serve } from "@photonjs/h3"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; import { createApp } from "h3"; async function startServer() { diff --git a/tests/app/hattip-entry.ts b/tests/app/hattip-entry.ts index 1469dfd4..4115a627 100644 --- a/tests/app/hattip-entry.ts +++ b/tests/app/hattip-entry.ts @@ -1,7 +1,7 @@ +import awesomeEntry from "virtual:ud:catch-all?default"; import { createRouter } from "@hattip/router"; import { apply, serve } from "@photonjs/hattip"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; function startServer() { const app = createRouter(); diff --git a/tests/app/hono-entry.ts b/tests/app/hono-entry.ts index a689069c..c2e9f07d 100644 --- a/tests/app/hono-entry.ts +++ b/tests/app/hono-entry.ts @@ -1,13 +1,12 @@ -import { apply, serve } from "@photonjs/hono"; +import awesomeEntry from "virtual:ud:catch-all?default"; +import { serve } from "@photonjs/hono"; +import { apply } from "@universal-middleware/hono"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; import { Hono } from "hono"; function startServer() { const app = new Hono(); - apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); - app.get("/serverid", () => { return new Response("hono", { status: 200, @@ -17,6 +16,8 @@ function startServer() { }); }); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + return serve(app); } diff --git a/tests/app/package.json b/tests/app/package.json index faf0dded..8a69afb8 100644 --- a/tests/app/package.json +++ b/tests/app/package.json @@ -21,7 +21,7 @@ "@photonjs/srvx": "workspace:0.1.12", "@types/express": "^5.0.6", "@types/node": "^22.19.1", - "@universal-deploy/store": "^0.0.2", + "@universal-deploy/store": "^0.0.5", "@universal-middleware/core": "^0.4.14", "pkg-types": "^2.3.0", "typescript": "^5.9.3", @@ -30,6 +30,7 @@ }, "dependencies": { "@hattip/router": "^0.0.49", + "@universal-middleware/hono": "^0.4.20", "awesome-framework": "workspace:", "elysia": "^1.4.19", "express": "^5.2.1", diff --git a/tests/app/srvx-entry.ts b/tests/app/srvx-entry.ts index 01e1cb41..999e491c 100644 --- a/tests/app/srvx-entry.ts +++ b/tests/app/srvx-entry.ts @@ -1,6 +1,6 @@ +import awesomeEntry from "virtual:ud:catch-all?default"; import { apply, serve } from "@photonjs/srvx"; import awesomeMiddlewares from "awesome-framework/middlewares"; -import awesomeEntry from "awesome-framework/server-entry"; function startServer() { const app = apply([...awesomeMiddlewares, awesomeEntry.fetch]); diff --git a/tests/app/virtual.d.ts b/tests/app/virtual.d.ts new file mode 100644 index 00000000..5608c611 --- /dev/null +++ b/tests/app/virtual.d.ts @@ -0,0 +1,5 @@ +declare module "virtual:ud:catch-all?default" { + export default { + fetch(request: Request): Response | Promise {}, + }; +} diff --git a/tests/app/vite.config.ts b/tests/app/vite.config.ts index a1729af6..04e383be 100644 --- a/tests/app/vite.config.ts +++ b/tests/app/vite.config.ts @@ -22,6 +22,22 @@ export default defineConfig({ // }), // not needed when using @photonjs/auto // target === "vercel" && vercel(), awesomeFramework(), + { + name: "resolve-local-entry", + resolveId: { + order: "pre", + filter: { + id: { + include: [/^virtual:ud:catch-all$/], + }, + }, + async handler(_, importer, opts) { + const res = await this.resolve(`./${server}-entry.ts`, importer, opts); + console.log(server, res); + return res; + }, + }, + }, ], build: { emptyOutDir: true, From 40386dfcfcb77644b22fec1a9db9aaf1122bcc38 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Wed, 21 Jan 2026 16:11:01 +0100 Subject: [PATCH 05/62] chore: remove apply from hono and hattip --- packages/hattip/package.json | 20 -------------------- packages/hattip/src/apply-dev.ts | 15 --------------- packages/hattip/src/apply-edge.ts | 8 -------- packages/hattip/src/apply-node.ts | 8 -------- packages/hattip/src/index.ts | 1 - packages/hattip/tsdown.config.ts | 14 +------------- packages/hono/package.json | 20 -------------------- packages/hono/src/apply-dev.ts | 14 -------------- packages/hono/src/apply-edge.ts | 8 -------- packages/hono/src/apply-node.ts | 8 -------- packages/hono/src/index.ts | 1 - packages/hono/tsdown.config.ts | 14 +------------- pnpm-lock.yaml | 27 ++++++++++++++++++++++++--- tests/app/hattip-entry.ts | 7 ++++--- tests/app/package.json | 1 + 15 files changed, 31 insertions(+), 135 deletions(-) delete mode 100644 packages/hattip/src/apply-dev.ts delete mode 100644 packages/hattip/src/apply-edge.ts delete mode 100644 packages/hattip/src/apply-node.ts delete mode 100644 packages/hono/src/apply-dev.ts delete mode 100644 packages/hono/src/apply-edge.ts delete mode 100644 packages/hono/src/apply-node.ts diff --git a/packages/hattip/package.json b/packages/hattip/package.json index 78834dfc..0bfda083 100644 --- a/packages/hattip/package.json +++ b/packages/hattip/package.json @@ -6,26 +6,6 @@ "types": "./dist/index.d.ts", "exports": { ".": "./dist/index.js", - "./apply": { - "types": "./dist/apply.d.ts", - "development": { - "types": "./dist/apply.dev.d.ts", - "import": "./dist/apply.dev.js", - "default": "./dist/apply.dev.js" - }, - "workerd": { - "types": "./dist/apply.edge.d.ts", - "import": "./dist/apply.edge.js", - "default": "./dist/apply.edge.js" - }, - "worker": { - "types": "./dist/apply.edge.d.ts", - "import": "./dist/apply.edge.js", - "default": "./dist/apply.edge.js" - }, - "import": "./dist/apply.js", - "default": "./dist/apply.js" - }, "./serve": "./dist/serve.js" }, "scripts": { diff --git a/packages/hattip/src/apply-dev.ts b/packages/hattip/src/apply-dev.ts deleted file mode 100644 index 0616875e..00000000 --- a/packages/hattip/src/apply-dev.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:dev:hattip"; -import { createApply } from "@photonjs/core/apply"; -import { devServerMiddleware } from "@photonjs/core/dev"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/hattip"; - -export const apply = createApply( - "hattip", - applyAdapter, - getUniversalEntries, - getUniversalMiddlewares, - devServerMiddleware, -); - -export type RuntimeAdapter = RuntimeAdapterTarget<"hattip">; diff --git a/packages/hattip/src/apply-edge.ts b/packages/hattip/src/apply-edge.ts deleted file mode 100644 index e90c7e3b..00000000 --- a/packages/hattip/src/apply-edge.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:edge:hattip"; -import { createApply } from "@photonjs/core/apply"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/hattip"; - -export const apply = createApply("hattip", applyAdapter, getUniversalEntries, getUniversalMiddlewares); - -export type RuntimeAdapter = RuntimeAdapterTarget<"hattip">; diff --git a/packages/hattip/src/apply-node.ts b/packages/hattip/src/apply-node.ts deleted file mode 100644 index 892e117a..00000000 --- a/packages/hattip/src/apply-node.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:node:hattip"; -import { createApply } from "@photonjs/core/apply"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/hattip"; - -export const apply = createApply("hattip", applyAdapter, getUniversalEntries, getUniversalMiddlewares); - -export type RuntimeAdapter = RuntimeAdapterTarget<"hattip">; diff --git a/packages/hattip/src/index.ts b/packages/hattip/src/index.ts index f46ad9b2..63e9e802 100644 --- a/packages/hattip/src/index.ts +++ b/packages/hattip/src/index.ts @@ -1,2 +1 @@ -export { apply, type RuntimeAdapter } from "@photonjs/hattip/apply"; export { serve } from "@photonjs/hattip/serve"; diff --git a/packages/hattip/tsdown.config.ts b/packages/hattip/tsdown.config.ts index 3ed8d61a..7384f054 100644 --- a/packages/hattip/tsdown.config.ts +++ b/packages/hattip/tsdown.config.ts @@ -8,7 +8,7 @@ const commonOptions: TsdownOptions = { treeshake: true, nodeProtocol: true, fixedExtension: false, - external: [/^virtual:photon:get-middlewares:/, /^@photonjs\/core/, /^@photonjs\/hattip/], + external: [/^@photonjs\/core/, /^@photonjs\/hattip/], }; export default defineConfig([ @@ -18,18 +18,6 @@ export default defineConfig([ entry: { // serve serve: "./src/serve.ts", - // apply (edge) - "apply.edge": "./src/apply-edge.ts", - }, - }, - { - ...commonOptions, - platform: "node", - entry: { - // apply (dev) - "apply.dev": "./src/apply-dev.ts", - // apply (node) - apply: "./src/apply-node.ts", }, }, { diff --git a/packages/hono/package.json b/packages/hono/package.json index 118db05a..c4635756 100644 --- a/packages/hono/package.json +++ b/packages/hono/package.json @@ -6,26 +6,6 @@ "types": "./dist/index.d.ts", "exports": { ".": "./dist/index.js", - "./apply": { - "types": "./dist/apply.d.ts", - "development": { - "types": "./dist/apply.dev.d.ts", - "import": "./dist/apply.dev.js", - "default": "./dist/apply.dev.js" - }, - "workerd": { - "types": "./dist/apply.edge.d.ts", - "import": "./dist/apply.edge.js", - "default": "./dist/apply.edge.js" - }, - "worker": { - "types": "./dist/apply.edge.d.ts", - "import": "./dist/apply.edge.js", - "default": "./dist/apply.edge.js" - }, - "import": "./dist/apply.js", - "default": "./dist/apply.js" - }, "./serve": { "workerd": "./dist/serve.edge.js", "worker": "./dist/serve.edge.js", diff --git a/packages/hono/src/apply-dev.ts b/packages/hono/src/apply-dev.ts deleted file mode 100644 index 7add583a..00000000 --- a/packages/hono/src/apply-dev.ts +++ /dev/null @@ -1,14 +0,0 @@ -import { createApply } from "@photonjs/core/apply"; -import { devServerMiddleware } from "@photonjs/core/dev"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/hono"; - -export const apply = createApply( - "hono", - applyAdapter, - () => [], - () => [], - devServerMiddleware, -); - -export type RuntimeAdapter = RuntimeAdapterTarget<"hono">; diff --git a/packages/hono/src/apply-edge.ts b/packages/hono/src/apply-edge.ts deleted file mode 100644 index ae584cb7..00000000 --- a/packages/hono/src/apply-edge.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:edge:hono"; -import { createApply } from "@photonjs/core/apply"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/hono"; - -export const apply = createApply("hono", applyAdapter, getUniversalEntries, getUniversalMiddlewares); - -export type RuntimeAdapter = RuntimeAdapterTarget<"hono">; diff --git a/packages/hono/src/apply-node.ts b/packages/hono/src/apply-node.ts deleted file mode 100644 index 51a295db..00000000 --- a/packages/hono/src/apply-node.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:node:hono"; -import { createApply } from "@photonjs/core/apply"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/hono"; - -export const apply = createApply("hono", applyAdapter, getUniversalEntries, getUniversalMiddlewares); - -export type RuntimeAdapter = RuntimeAdapterTarget<"hono">; diff --git a/packages/hono/src/index.ts b/packages/hono/src/index.ts index d24e0557..9c329859 100644 --- a/packages/hono/src/index.ts +++ b/packages/hono/src/index.ts @@ -1,2 +1 @@ -export { apply, type RuntimeAdapter } from "@photonjs/hono/apply"; export { serve } from "@photonjs/hono/serve"; diff --git a/packages/hono/tsdown.config.ts b/packages/hono/tsdown.config.ts index 662b9131..28d9d6a8 100644 --- a/packages/hono/tsdown.config.ts +++ b/packages/hono/tsdown.config.ts @@ -8,7 +8,7 @@ const commonOptions: TsdownOptions = { treeshake: true, nodeProtocol: true, fixedExtension: false, - external: ["hono", "@hono/node-server", /^virtual:photon:get-middlewares:/, /^@photonjs\/core/, /^@photonjs\/hono/], + external: ["hono", "@hono/node-server", /^@photonjs\/core/, /^@photonjs\/hono/], }; export default defineConfig([ @@ -20,18 +20,6 @@ export default defineConfig([ serve: "./src/serve.ts", // serve (edge) "serve.edge": "./src/serve-edge.ts", - // apply (edge) - "apply.edge": "./src/apply-edge.ts", - }, - }, - { - ...commonOptions, - platform: "node", - entry: { - // apply (dev) - "apply.dev": "./src/apply-dev.ts", - // apply (node) - apply: "./src/apply-node.ts", }, }, { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b61e1365..d12484ef 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -632,6 +632,9 @@ importers: '@hattip/router': specifier: ^0.0.49 version: 0.0.49 + '@universal-middleware/hattip': + specifier: ^0.4.15 + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/hono': specifier: ^0.4.20 version: 0.4.20(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -3072,6 +3075,9 @@ packages: '@universal-middleware/hattip@0.4.14': resolution: {integrity: sha512-8goLMiH5TeDLjNF8687j+GxWnokfq0dMSfEJjWT9BvvRmyMs4p42UztewPx103xjgOw9BO5fGBKu4Fmq0I5FBw==} + '@universal-middleware/hattip@0.4.15': + resolution: {integrity: sha512-uBGMSN2hTdmkpWH8jt/UKGGXpJJhSBnXp/0HQRuzhZs3Ip2ubtX5K8/Iq/cAA2AG3ZYJA19+vo6+86to5ZiujA==} + '@universal-middleware/hono@0.4.18': resolution: {integrity: sha512-RpnX8hKh2zx7hwVYzI32DjvH7KBYpt7MLIHWYw9QBSEzpD1ErqL+SpkvvlJaINjFs+sYJKH5IOoL53uHCL5alw==} @@ -8257,11 +8263,12 @@ snapshots: hono: 4.11.1 srvx: 0.9.8 - '@universal-middleware/core@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/core@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: regexparam: 3.0.0 tough-cookie: 6.0.0 optionalDependencies: + '@cloudflare/workers-types': 4.20251219.0 '@hattip/core': 0.0.49 '@types/express': 5.0.6 elysia: 1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3) @@ -8342,6 +8349,20 @@ snapshots: - hono - srvx + '@universal-middleware/hattip@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + dependencies: + '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + transitivePeerDependencies: + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@webroute/route' + - elysia + - fastify + - h3 + - hono + - srvx + '@universal-middleware/hono@0.4.18(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -8358,7 +8379,7 @@ snapshots: '@universal-middleware/hono@0.4.20(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8391,7 +8412,7 @@ snapshots: '@universal-middleware/vercel@0.4.29(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) optionalDependencies: '@hattip/core': 0.0.49 diff --git a/tests/app/hattip-entry.ts b/tests/app/hattip-entry.ts index 4115a627..c55265ed 100644 --- a/tests/app/hattip-entry.ts +++ b/tests/app/hattip-entry.ts @@ -1,13 +1,12 @@ import awesomeEntry from "virtual:ud:catch-all?default"; import { createRouter } from "@hattip/router"; -import { apply, serve } from "@photonjs/hattip"; +import { serve } from "@photonjs/hattip"; +import { apply } from "@universal-middleware/hattip"; import awesomeMiddlewares from "awesome-framework/middlewares"; function startServer() { const app = createRouter(); - apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); - app.get("/serverid", () => { return new Response("hattip", { status: 200, @@ -17,6 +16,8 @@ function startServer() { }); }); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + return serve(app); } diff --git a/tests/app/package.json b/tests/app/package.json index 8a69afb8..e65d8190 100644 --- a/tests/app/package.json +++ b/tests/app/package.json @@ -30,6 +30,7 @@ }, "dependencies": { "@hattip/router": "^0.0.49", + "@universal-middleware/hattip": "^0.4.15", "@universal-middleware/hono": "^0.4.20", "awesome-framework": "workspace:", "elysia": "^1.4.19", From a82cfa2a0b722e908f7bb81571a84a9954a18499 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Wed, 21 Jan 2026 16:16:06 +0100 Subject: [PATCH 06/62] wip: express --- packages/express/package.json | 10 ---------- packages/express/src/apply-dev.ts | 15 --------------- packages/express/src/apply-node.ts | 8 -------- packages/express/src/index.ts | 1 - packages/express/tsdown.config.ts | 12 +----------- pnpm-lock.yaml | 24 ++++++++++++++++++++++-- tests/app/express-entry.ts | 7 ++++--- tests/app/package.json | 1 + 8 files changed, 28 insertions(+), 50 deletions(-) delete mode 100644 packages/express/src/apply-dev.ts delete mode 100644 packages/express/src/apply-node.ts diff --git a/packages/express/package.json b/packages/express/package.json index 188f77ed..f727d819 100644 --- a/packages/express/package.json +++ b/packages/express/package.json @@ -6,16 +6,6 @@ "types": "./dist/index.d.ts", "exports": { ".": "./dist/index.js", - "./apply": { - "types": "./dist/apply.d.ts", - "development": { - "types": "./dist/apply.dev.d.ts", - "import": "./dist/apply.dev.js", - "default": "./dist/apply.dev.js" - }, - "import": "./dist/apply.js", - "default": "./dist/apply.js" - }, "./serve": "./dist/serve.js" }, "scripts": { diff --git a/packages/express/src/apply-dev.ts b/packages/express/src/apply-dev.ts deleted file mode 100644 index 6f5299ea..00000000 --- a/packages/express/src/apply-dev.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:dev:express"; -import { createApply } from "@photonjs/core/apply"; -import { devServerMiddleware } from "@photonjs/core/dev"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/express"; - -export const apply = createApply( - "express", - applyAdapter, - getUniversalEntries, - getUniversalMiddlewares, - devServerMiddleware, -); - -export type RuntimeAdapter = RuntimeAdapterTarget<"express">; diff --git a/packages/express/src/apply-node.ts b/packages/express/src/apply-node.ts deleted file mode 100644 index baacb7d6..00000000 --- a/packages/express/src/apply-node.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:node:express"; -import { createApply } from "@photonjs/core/apply"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/express"; - -export const apply = createApply("express", applyAdapter, getUniversalEntries, getUniversalMiddlewares); - -export type RuntimeAdapter = RuntimeAdapterTarget<"express">; diff --git a/packages/express/src/index.ts b/packages/express/src/index.ts index db8d977e..5db7defa 100644 --- a/packages/express/src/index.ts +++ b/packages/express/src/index.ts @@ -1,2 +1 @@ -export { apply, type RuntimeAdapter } from "@photonjs/express/apply"; export { serve } from "@photonjs/express/serve"; diff --git a/packages/express/tsdown.config.ts b/packages/express/tsdown.config.ts index 0f474cf2..00cd574d 100644 --- a/packages/express/tsdown.config.ts +++ b/packages/express/tsdown.config.ts @@ -8,7 +8,7 @@ const commonOptions: TsdownOptions = { treeshake: true, nodeProtocol: true, fixedExtension: false, - external: ["express", /^virtual:photon:get-middlewares:/, /^@photonjs\/core/, /^@photonjs\/express/], + external: ["express", /^@photonjs\/core/, /^@photonjs\/express/], }; export default defineConfig([ @@ -20,16 +20,6 @@ export default defineConfig([ serve: "./src/serve.ts", }, }, - { - ...commonOptions, - platform: "node", - entry: { - // apply (dev) - "apply.dev": "./src/apply-dev.ts", - // apply (node) - apply: "./src/apply-node.ts", - }, - }, { ...commonOptions, platform: "neutral", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index d12484ef..3e0012dd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -632,6 +632,9 @@ importers: '@hattip/router': specifier: ^0.0.49 version: 0.0.49 + '@universal-middleware/express': + specifier: ^0.4.23 + version: 0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/hattip': specifier: ^0.4.15 version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -3066,6 +3069,9 @@ packages: '@universal-middleware/express@0.4.22': resolution: {integrity: sha512-4aIrnK52NJmYKokZnwpWja/vT2m/HoZ8zxQyYLdokkSQdx0B1k1VsmYGeWENvpDQBgLjnfyvDzyaxch6Tib/hA==} + '@universal-middleware/express@0.4.23': + resolution: {integrity: sha512-wFM9HQWIXrK+CJvld95bwkGbb1wA/bKkwBBKI5njPShVCMayFoSDb6FMrqezHqI3hGBcjUs9D17CVIJa6gzdPA==} + '@universal-middleware/fastify@0.5.22': resolution: {integrity: sha512-6axgXhhi69V4RHh6DjUxRmWnRN8U9cW/Ro/1lB0weTe4Y07pI/9603XGcg9iNltbqEhjRvK+Jch3WwwIfVdIBg==} @@ -7299,7 +7305,7 @@ snapshots: '@universal-middleware/cloudflare': 0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/compress': 0.2.34 '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/express': 0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': 0.1.24 estree-walker: 3.0.3 ts-deepmerge: 7.0.3 @@ -8305,6 +8311,20 @@ snapshots: - hono - srvx + '@universal-middleware/express@0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + dependencies: + '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + transitivePeerDependencies: + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@webroute/route' + - elysia + - fastify + - h3 + - hono + - srvx + '@universal-middleware/fastify@0.5.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -8413,7 +8433,7 @@ snapshots: '@universal-middleware/vercel@0.4.29(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/express': 0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) optionalDependencies: '@hattip/core': 0.0.49 '@universal-middleware/h3': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) diff --git a/tests/app/express-entry.ts b/tests/app/express-entry.ts index 8438d188..de5f1f6a 100644 --- a/tests/app/express-entry.ts +++ b/tests/app/express-entry.ts @@ -1,18 +1,19 @@ import awesomeEntry from "virtual:ud:catch-all?default"; import type { ServeReturn } from "@photonjs/core/serve"; -import { apply, serve } from "@photonjs/express"; +import { serve } from "@photonjs/express"; +import { apply } from "@universal-middleware/express"; import awesomeMiddlewares from "awesome-framework/middlewares"; import express, { type Express } from "express"; function startServer(): ServeReturn { const app = express(); - apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); - app.get("/serverid", (_, res) => { res.status(200).send("express"); }); + apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + return serve(app); } diff --git a/tests/app/package.json b/tests/app/package.json index e65d8190..14e51a3a 100644 --- a/tests/app/package.json +++ b/tests/app/package.json @@ -30,6 +30,7 @@ }, "dependencies": { "@hattip/router": "^0.0.49", + "@universal-middleware/express": "^0.4.23", "@universal-middleware/hattip": "^0.4.15", "@universal-middleware/hono": "^0.4.20", "awesome-framework": "workspace:", From cf3a0c848f207e5fbb227e6cd20737aadca7645f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Wed, 21 Jan 2026 16:52:07 +0100 Subject: [PATCH 07/62] wip --- packages/core/src/api.ts | 29 -- packages/core/src/index.ts | 22 -- packages/core/src/middlewares/devServer.ts | 31 --- packages/core/src/plugin/index.ts | 46 +--- packages/core/tsdown.config.ts | 3 - packages/hono/package.json | 1 - packages/hono/src/serve.ts | 3 +- packages/runtime/package.json | 2 +- packages/runtime/src/index.ts | 3 +- packages/runtime/src/serve-dev.ts | 19 -- packages/runtime/src/serve-utils.ts | 5 +- packages/runtime/src/serve.ts | 14 +- packages/runtime/src/utils.ts | 13 +- packages/runtime/src/vite.ts | 291 +-------------------- packages/runtime/tsdown.config.ts | 3 +- packages/runtime/virtual.d.ts | 2 +- pnpm-lock.yaml | 34 ++- tests/app/vite.config.ts | 2 + 18 files changed, 62 insertions(+), 461 deletions(-) delete mode 100644 packages/core/src/api.ts delete mode 100644 packages/core/src/middlewares/devServer.ts delete mode 100644 packages/runtime/src/serve-dev.ts diff --git a/packages/core/src/api.ts b/packages/core/src/api.ts deleted file mode 100644 index 73f0a580..00000000 --- a/packages/core/src/api.ts +++ /dev/null @@ -1,29 +0,0 @@ -import type { Photon } from "./types.js"; - -export { - addPhotonEntry, - getPhotonServerIdWithEntry, - updatePhotonEntry, -} from "./api/api.js"; -export { isPhotonMeta, type PhotonMeta } from "./plugin/utils/entry.js"; -export { - PhotonBugError, - PhotonConfigError, - PhotonDependencyError, - PhotonError, - PhotonRuntimeError, - PhotonUsageError, -} from "./utils/assert.js"; -export { getPhotonMeta } from "./utils/meta.js"; -export { resolvePhotonConfig } from "./validators/coerce.js"; - -declare module "vite" { - interface UserConfig { - photon?: Photon.Config | Photon.Config[]; - afterBuildStart?: boolean; - } - - interface ResolvedConfig { - photon: Photon.ConfigResolved; - } -} diff --git a/packages/core/src/index.ts b/packages/core/src/index.ts index 66988b7f..a9bf73cb 100644 --- a/packages/core/src/index.ts +++ b/packages/core/src/index.ts @@ -1,23 +1 @@ -import type { Photon } from "./types.js"; - -export * as api from "./api.js"; export type { Photon } from "./types.js"; -export { - PhotonBugError, - PhotonConfigError, - PhotonDependencyError, - PhotonError, - PhotonRuntimeError, - PhotonUsageError, -} from "./utils/assert.js"; - -declare module "vite" { - interface UserConfig { - photon?: Photon.Config | Photon.Config[]; - afterBuildStart?: boolean; - } - - interface ResolvedConfig { - photon: Photon.ConfigResolved; - } -} diff --git a/packages/core/src/middlewares/devServer.ts b/packages/core/src/middlewares/devServer.ts deleted file mode 100644 index 80bf5ed0..00000000 --- a/packages/core/src/middlewares/devServer.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { enhance, type Get, type UniversalMiddleware } from "@universal-middleware/core"; -import { handleViteDevServer } from "../runtime/adapters/handleViteDevServer.js"; -import { globalStore } from "../runtime/globalStore.js"; - -export const devServerMiddleware = (() => - enhance( - async (request, context, runtime) => { - // Can be disabled, or can be running on a different environment - if (!globalStore.viteDevServer) return; - - const { connectToWeb } = await import("@universal-middleware/express"); - const handled = await connectToWeb(handleViteDevServer)(request, context, runtime); - - if (handled) return handled; - - return (response) => { - if (!response.headers.has("ETag")) { - try { - response.headers.set("Cache-Control", "no-store"); - } catch { - // Headers already sent - } - } - return response; - }; - }, - { - name: "photon:dev-server", - immutable: false, - }, - )) satisfies Get<[], UniversalMiddleware>; diff --git a/packages/core/src/plugin/index.ts b/packages/core/src/plugin/index.ts index e116b785..b5627d70 100644 --- a/packages/core/src/plugin/index.ts +++ b/packages/core/src/plugin/index.ts @@ -1,51 +1,9 @@ import type { Plugin } from "vite"; import type { Photon } from "../types.js"; -import { commonConfig } from "./plugins/commonConfig.js"; import { devServer } from "./plugins/devServer.js"; -import { getMiddlewaresPlugin } from "./plugins/getMiddlewaresPlugin.js"; -import { type InstallPhotonBaseOptions, installPhotonResolver, simplePhotonResolver } from "./plugins/installPhoton.js"; -import { mirrorMeta } from "./plugins/mirrorMeta.js"; -import { photonEntry } from "./plugins/photonEntry.js"; -import { resolvePhotonConfigPlugin } from "./plugins/resolvePhotonConfigPlugin.js"; -import { supportedTargetServers } from "./plugins/supportedServers.js"; -import { targetLoader } from "./plugins/targetLoader.js"; -export { - photon, - installPhotonCore, - installPhotonResolver, - supportedTargetServers, - targetLoader, - type InstallPhotonCoreOptions, - photon as default, -}; +export { photon, photon as default }; function photon(config?: Photon.Config): Plugin[] { - return [ - ...commonConfig(), - ...resolvePhotonConfigPlugin(config), - simplePhotonResolver(), - ...photonEntry(), - ...mirrorMeta(), - - devServer(config), - ...getMiddlewaresPlugin(), - ]; -} - -type InstallPhotonCoreOptions = InstallPhotonBaseOptions & Photon.Config; - -function installPhotonCore(name: string, options?: InstallPhotonCoreOptions): Plugin[] { - return [...photon(options), ...installPhotonResolver(name, options)]; -} - -declare module "vite" { - interface UserConfig { - photon?: Photon.Config | Photon.Config[]; - afterBuildStart?: boolean; - } - - interface ResolvedConfig { - photon: Photon.ConfigResolved; - } + return [devServer(config)]; } diff --git a/packages/core/tsdown.config.ts b/packages/core/tsdown.config.ts index 097f9194..4c6294ae 100644 --- a/packages/core/tsdown.config.ts +++ b/packages/core/tsdown.config.ts @@ -17,10 +17,8 @@ export default defineConfig([ platform: "node", entry: { plugin: "./src/plugin/index.ts", - api: "./src/api.ts", internal: "./src/api/internal.ts", dev: "./src/dev.ts", - assert: "./src/utils/assert.ts", index: "./src/index.ts", }, }, @@ -29,7 +27,6 @@ export default defineConfig([ platform: "neutral", entry: { // utils - apply: "./src/apply.ts", serve: "./src/serve.ts", }, }, diff --git a/packages/hono/package.json b/packages/hono/package.json index c4635756..69fac3b7 100644 --- a/packages/hono/package.json +++ b/packages/hono/package.json @@ -19,7 +19,6 @@ "test:types": "tsc --noEmit" }, "dependencies": { - "@photonjs/core": "workspace:^", "@universal-middleware/hono": "^0.4.18" }, "peerDependencies": { diff --git a/packages/hono/src/serve.ts b/packages/hono/src/serve.ts index ce617a55..0296ffd1 100644 --- a/packages/hono/src/serve.ts +++ b/packages/hono/src/serve.ts @@ -1,5 +1,4 @@ import type { IncomingMessage, ServerResponse } from "node:http"; -import { PhotonDependencyError } from "@photonjs/core/errors"; import type { NodeHandler, ServeReturn } from "@photonjs/core/serve"; import type { App as HonoApp } from "@universal-middleware/hono"; import type { MergedHonoServerOptions } from "./types.js"; @@ -21,7 +20,7 @@ export function serve(app: App, options: MergedHonoServerOp nodeHandler = listener; return listener(incoming, outgoing); } catch (e) { - throw new PhotonDependencyError(`Missing @hono/node-server package. Add it to your dependencies`, { cause: e }); + throw new Error(`Missing @hono/node-server package. Add it to your dependencies`, { cause: e }); } }; nodeHandler = honoHandler; diff --git a/packages/runtime/package.json b/packages/runtime/package.json index 2730b2c1..fb35c52f 100644 --- a/packages/runtime/package.json +++ b/packages/runtime/package.json @@ -21,10 +21,10 @@ "test:types": "tsc --noEmit" }, "dependencies": { - "@photonjs/core": "workspace:^", "@photonjs/srvx": "workspace:^", "@universal-middleware/core": "^0.4.14", "@universal-middleware/sirv": "^0.1.24", + "@universal-deploy/node": "^0.0.1", "srvx": "^0.9.8", "standaloner": "^0.1.11" }, diff --git a/packages/runtime/src/index.ts b/packages/runtime/src/index.ts index 3e1a596c..5be45c66 100644 --- a/packages/runtime/src/index.ts +++ b/packages/runtime/src/index.ts @@ -1,2 +1 @@ -// Re-export only the vite plugins with fallback -export { installPhoton, photon, photon as default } from "./vite.js"; +export { serve } from "./vite.js"; diff --git a/packages/runtime/src/serve-dev.ts b/packages/runtime/src/serve-dev.ts deleted file mode 100644 index abf66b17..00000000 --- a/packages/runtime/src/serve-dev.ts +++ /dev/null @@ -1,19 +0,0 @@ -import userServerEntry from "virtual:photon:server-entry"; -import { installServerHMR, isBun, isDeno, nodeServe, srvxServe } from "./serve-utils.js"; -import { assertServerEntry } from "./utils.js"; - -async function startServer() { - assertServerEntry(userServerEntry); - - const _serve = - isBun || isDeno || !userServerEntry.server?.nodeHandler - ? // biome-ignore lint/style/noNonNullAssertion: already asserted - () => srvxServe(userServerEntry!) - : () => - // biome-ignore lint/style/noNonNullAssertion: already asserted - nodeServe(userServerEntry!.server?.options ?? {}, userServerEntry!.server!.nodeHandler!); - - return installServerHMR(_serve); -} - -await startServer(); diff --git a/packages/runtime/src/serve-utils.ts b/packages/runtime/src/serve-utils.ts index 3bdd9588..cfe8debe 100644 --- a/packages/runtime/src/serve-utils.ts +++ b/packages/runtime/src/serve-utils.ts @@ -1,7 +1,6 @@ import nodeHTTP from "node:http"; import nodeHTTP2 from "node:http2"; import type { Socket } from "node:net"; -import { PhotonBugError } from "@photonjs/core/errors"; import type { NodeHandler, ServeReturn, ServerOptions, ServerType } from "@photonjs/core/serve"; import type { Server as SrvxServer, ServerOptions as SrvxServerOptions } from "srvx"; import { serve as serveSrvx } from "srvx"; @@ -188,7 +187,7 @@ async function onServerClose(serverP: Servers | Promise) { }; } - throw new PhotonBugError( + throw new Error( "server-side HMR is not supported for Deno. You can disable it by settings `photon.hmr = 'prefer-restart'`", ); } else if ("stop" in server) { @@ -199,7 +198,7 @@ async function onServerClose(serverP: Servers | Promise) { } if (!("on" in server)) { - throw new PhotonBugError( + throw new Error( "server-side HMR is not supported for this server. You can disable it by settings `photon.hmr = 'prefer-restart'`", ); } diff --git a/packages/runtime/src/serve.ts b/packages/runtime/src/serve.ts index d8875e41..e964fce6 100644 --- a/packages/runtime/src/serve.ts +++ b/packages/runtime/src/serve.ts @@ -1,14 +1,14 @@ -import userServerEntry from "virtual:photon:server-entry"; -import { isBun, isDeno, nodeServe, srvxServe } from "./serve-utils.js"; +import maybeServerEntry from "virtual:ud:catch-all"; +import { isBun, isDeno, nodeServe } from "./serve-utils.js"; import { assertServerEntry } from "./utils.js"; -function startServer() { - assertServerEntry(userServerEntry); +async function startServer() { + assertServerEntry(maybeServerEntry); - if (isBun || isDeno || !userServerEntry.server?.nodeHandler) { - return srvxServe(userServerEntry); + if (isBun || isDeno || !maybeServerEntry.server?.nodeHandler) { + return await import("@universal-deploy/node/serve"); } - return nodeServe(userServerEntry.server?.options ?? {}, userServerEntry.server.nodeHandler); + return nodeServe(maybeServerEntry.server?.options ?? {}, maybeServerEntry.server.nodeHandler); } await startServer(); diff --git a/packages/runtime/src/utils.ts b/packages/runtime/src/utils.ts index af1fc39a..fac4027e 100644 --- a/packages/runtime/src/utils.ts +++ b/packages/runtime/src/utils.ts @@ -1,14 +1,13 @@ -import type { Fetchable } from "@photonjs/core/api/internal"; -import { PhotonRuntimeError } from "@photonjs/core/errors"; - -export function assertServerEntry(entry: T): asserts entry is T & Fetchable { +export function assertServerEntry( + entry: T, +): asserts entry is T & { fetch: (request: Request) => Response | Promise } { if (!entry) { - throw new PhotonRuntimeError("Server entry must have a default export"); + throw new Error("Server entry must have a default export"); } if (typeof entry !== "object") { - throw new PhotonRuntimeError("Server entry default export must be an object"); + throw new Error("Server entry default export must be an object"); } if (!("fetch" in entry)) { - throw new PhotonRuntimeError("Server entry default export must include a 'fetch' method"); + throw new Error("Server entry default export must include a 'fetch' method"); } } diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index eb201532..5637cbba 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -1,199 +1,32 @@ -import type { Photon } from "@photonjs/core"; -import { resolvePhotonConfig } from "@photonjs/core/api"; -import { resolveFirst, singleton } from "@photonjs/core/api/internal"; -import { assert } from "@photonjs/core/errors"; -import { photon as corePhoton, type InstallPhotonCoreOptions, installPhotonCore } from "@photonjs/core/vite"; -import standaloner from "standaloner/vite"; import type { Plugin } from "vite"; -interface PhotonPluginOptions { - /** - * Set this to true if you're using a framework that doesn’t integrate - * with Photon directly but provides an SSR entry that exports - * `default { fetch }`. Photon will automatically wrap that entry for you. - * @experimental - */ - autoWrapEntry?: boolean | string; - /** - * Create self-contained, deployable Node.js applications by bundling your code and including necessary dependencies. - * @see {@link https://github.com/nitedani/standaloner/tree/main/standaloner} - */ - standalone?: boolean | Parameters[0]; -} - -const re_photonFallback = /^virtual:photon:fallback-entry$/; -const re_photonServe = /^virtual:photon:serve-entry$/; -const re_photonWrap = /^virtual:photon:wrap-fetch-entry:(.*)/; - -function fallback(): Plugin { - return singleton({ - name: "photon:fallback", - - resolveId: { - filter: { - id: re_photonFallback, - }, - handler(id) { - return { - id, - meta: { - photon: { - id, - resolvedId: id, - type: "server", - }, - }, - }; - }, - }, - - load: { - filter: { - id: re_photonFallback, - }, - handler() { - //language=js - return `import { apply } from "virtual:photon:resolve-from-photon:@photonjs/srvx"; - -const app = apply(); - -export default { - fetch: app, -}; -`; - }, - }, - }); -} - -function wrapSsrEntry(config?: Photon.Config & PhotonPluginOptions): Plugin { - return singleton({ - name: "photon:wrap-fetch-entry", - - config: { - handler(userConfig) { - const input = userConfig.environments?.ssr?.build?.rollupOptions?.input; - - const inputStr = - typeof config?.autoWrapEntry === "string" - ? config.autoWrapEntry - : typeof input === "string" - ? input - : Array.isArray(input) && input.length > 0 - ? (input[0] as string) - : input && "index" in input - ? (input.index as string) - : undefined; - - if (!inputStr || inputStr === "virtual:photon:fallback-entry") return; - - const resolvedPhotonConfig = resolvePhotonConfig(userConfig.photon); - - if (resolvedPhotonConfig.server.id) { - return { - photon: { - server: { - id: `virtual:photon:wrap-fetch-entry:${inputStr}`, - }, - }, - }; - } - }, - }, - - resolveId: { - filter: { - id: re_photonWrap, - }, - handler(id) { - return { - id, - meta: { - photon: { - id, - resolvedId: id, - type: "server", - }, - }, - }; - }, - }, - - load: { - filter: { - id: re_photonWrap, - }, - handler(id) { - const match = id.match(re_photonWrap); - // biome-ignore lint/style/noNonNullAssertion: asserted by filter - const actualId = match![1]; - - //language=js - return `import fetchableEntry from ${JSON.stringify(actualId)}; -import { apply } from "virtual:photon:resolve-from-photon:@photonjs/srvx"; -import { enhance } from 'virtual:photon:resolve-from-photon:@universal-middleware/core'; - -const app = apply([ - enhance(fetchableEntry.fetch, { - name: "photon:fetchable-entry", - immutable: true, - path: "/**", - method: ["GET", "POST"] - }) -]); - -export default { - fetch: app, -}; -`; - }, - }, - }); -} - -const nodeTargets = new Set(["node", "bun", "deno"]); - // Creates a server and listens for connections in Node/Deno/Bun -function serve(): Plugin[] { +export function serve(): Plugin[] { let userPort: number | undefined; let userHost: string | boolean | undefined; return [ - singleton({ - name: "photon:serve", + { + name: "photon:node:node-entry", + apply: "build", resolveId: { + order: "pre", filter: { - id: re_photonServe, + id: /^virtual:photon:node-entry$/, }, async handler(id, importer) { - const isDev = this.environment.config.command === "serve"; - const source = isDev ? "@photonjs/runtime/serve/dev" : "@photonjs/runtime/serve"; - const opts = {}; - const resolved = await resolveFirst(this, [ - { source: `virtual:photon:resolve-from-photon:${source}`, opts }, - { source: `virtual:photon:resolve-from-photon:${source}`, importer, opts }, - ]); - + const resolved = await this.resolve("@photonjs/runtime/serve", importer); if (!resolved) { throw new Error(`Cannot find server entry ${JSON.stringify(id)}`); } return { id: resolved.id, - meta: { - photon: { - id, - resolvedId: resolved.id, - }, - photonConfig: { - isTargetEntry: true, - }, - }, }; }, }, - }), - singleton({ + }, + { name: "photon:serve:transform-dev", apply: "serve", @@ -226,110 +59,6 @@ function serve(): Plugin[] { } }, }, - }), - singleton({ - name: "photon:serve:emit", - - apply: "build", - enforce: "post", - - config: { - order: "post", - handler(config) { - const photon = resolvePhotonConfig(config.photon); - - if (!photon.target || nodeTargets.has(photon.target)) { - return { - environments: { - [photon.defaultBuildEnv]: { - build: { - rollupOptions: { - input: { - index: "virtual:photon:serve-entry", - }, - }, - }, - }, - }, - }; - } - }, - }, - - configResolved({ photon }) { - // Add sirv middleware when targeting node, but only when fetchable entry is extracted from rollupOptions - if ( - photon.server.id.includes("virtual:photon:wrap-fetch-entry:") && - (!photon.target || nodeTargets.has(photon.target)) - ) { - photon.middlewares ??= []; - photon.middlewares.push((condition) => { - if (condition === "node") { - return "@photonjs/runtime/sirv"; - } - }); - } - }, - - sharedDuringBuild: true, - }), - ]; -} - -/** - * Ensures that the default build environment has an input defined. - */ -function input() { - return singleton({ - name: "photon:set-input", - configResolved(config) { - const envs = new Set([config.photon.defaultBuildEnv, "ssr"]); - for (const envName of envs) { - const env = config.environments[envName]; - if (envName === "ssr" && !env) continue; - assert(env); - const input = env.build.rollupOptions.input; - if ( - !input || - (Array.isArray(input) && input.length === 0) || - (typeof input === "object" && !Object.keys(input).includes("index")) - ) { - env.build.rollupOptions.input = { - ...(input && typeof input === "object" ? input : {}), - index: "virtual:photon:server-entry", - }; - } - } }, - }); -} - -// Export photon function that includes core plugins + fallback -export function photon(config?: Photon.Config & PhotonPluginOptions): Plugin[] { - const plugins = [...corePhoton(config)]; - - plugins.push(fallback()); - plugins.push(...serve()); - plugins.push(input()); - - if (config?.autoWrapEntry) { - plugins.push(wrapSsrEntry(config)); - } - - if (config?.standalone) { - plugins.push(...standaloner(typeof config.standalone === "object" ? config.standalone : {})); - } - - return plugins; -} - -/** - * All Photon's Vite plugins required for your library to operate correctly. - * @param name Your package name as specified in package.json - * @param options - */ -export function installPhoton(name: string, options?: InstallPhotonCoreOptions): Plugin[] { - const plugins = installPhotonCore(name, options); - - return [fallback(), ...serve(), input(), ...plugins]; + ]; } diff --git a/packages/runtime/tsdown.config.ts b/packages/runtime/tsdown.config.ts index 508e6eb8..fe1d1123 100644 --- a/packages/runtime/tsdown.config.ts +++ b/packages/runtime/tsdown.config.ts @@ -8,7 +8,7 @@ const commonOptions: TsdownOptions = { treeshake: true, nodeProtocol: true, fixedExtension: false, - external: [/^@photonjs\/core/, /^@photonjs\/hono/, /^virtual:photon:get-middlewares:/, "virtual:photon:server-entry"], + external: [/^@photonjs\/core/, /^@photonjs\/hono/, "virtual:photon:server-entry", "virtual:ud:catch-all"], }; export default defineConfig([ @@ -18,7 +18,6 @@ export default defineConfig([ entry: { vite: "./src/vite.ts", serve: "./src/serve.ts", - "serve-dev": "./src/serve-dev.ts", internal: "./src/internal.ts", index: "./src/index.ts", sirv: "./src/sirv.ts", diff --git a/packages/runtime/virtual.d.ts b/packages/runtime/virtual.d.ts index 403c5149..28f421d6 100644 --- a/packages/runtime/virtual.d.ts +++ b/packages/runtime/virtual.d.ts @@ -4,7 +4,7 @@ declare module "virtual:photon:fallback-entry" { export default handler; } -declare module "virtual:photon:server-entry" { +declare module "virtual:ud:catch-all" { const handler: undefined | import("@photonjs/core/serve").ServeReturn; export default handler; } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 3e0012dd..41a4de35 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -527,9 +527,6 @@ importers: packages/hono: dependencies: - '@photonjs/core': - specifier: workspace:^ - version: link:../core '@universal-middleware/hono': specifier: ^0.4.18 version: 0.4.18(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -561,12 +558,12 @@ importers: packages/runtime: dependencies: - '@photonjs/core': - specifier: workspace:^ - version: link:../core '@photonjs/srvx': specifier: workspace:^ version: link:../srvx + '@universal-deploy/node': + specifier: ^0.0.1 + version: 0.0.1(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@universal-middleware/core': specifier: ^0.4.14 version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -2990,6 +2987,14 @@ packages: '@ungap/structured-clone@1.3.0': resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} + '@universal-deploy/node@0.0.1': + resolution: {integrity: sha512-x9z72xNOo1ZqwrMOE1fF+NesvXHvk16bD306Gtyw9jABlAD8sSMyP8x9JaepswbE9N3jHQzBlu7wFolgMD4bLg==} + peerDependencies: + vite: '>=7.1' + peerDependenciesMeta: + vite: + optional: true + '@universal-deploy/store@0.0.5': resolution: {integrity: sha512-+V6twaKK+vLhjKlXpI6wZ0Ijm0/4EVSpjA+uzT7XzFflYmtFHGFQB3LGjzWfUo9UGRRf7LYarN5H4zbW+0UXJw==} @@ -8224,6 +8229,23 @@ snapshots: '@ungap/structured-clone@1.3.0': {} + '@universal-deploy/node@0.0.1(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + dependencies: + '@universal-deploy/store': 0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/sirv': 0.1.24 + srvx: 0.9.8 + optionalDependencies: + vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + transitivePeerDependencies: + - '@cloudflare/workers-types' + - '@hattip/core' + - '@types/express' + - '@webroute/route' + - elysia + - fastify + - h3 + - hono + '@universal-deploy/store@0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) diff --git a/tests/app/vite.config.ts b/tests/app/vite.config.ts index 04e383be..4b5b2145 100644 --- a/tests/app/vite.config.ts +++ b/tests/app/vite.config.ts @@ -1,5 +1,6 @@ // import { cloudflare } from "@photonjs/cloudflare/vite"; // import { vercel } from "@photonjs/vercel/vite"; +import { serve } from "@photonjs/runtime/vite"; import { store } from "@universal-deploy/store"; import { awesomeFramework } from "awesome-framework/vite"; import { defineConfig } from "vite"; @@ -21,6 +22,7 @@ export default defineConfig({ // inspectorPort: false, // }), // not needed when using @photonjs/auto // target === "vercel" && vercel(), + target === "node" && serve(), awesomeFramework(), { name: "resolve-local-entry", From dea3e34485f4337c5c98694eb1627f484d5a6cdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 16:21:19 +0100 Subject: [PATCH 08/62] wip --- docs/package.json | 2 +- example/app-cloudflare/package.json | 2 +- example/app-hono/package.json | 2 +- example/app-netlify/package.json | 2 +- example/app-vercel/package.json | 2 +- example/awesome-framework/package.json | 2 +- example/tanstack-start/package.json | 2 +- packages/core/package.json | 2 +- packages/elysia/package.json | 2 +- packages/express/package.json | 14 +- packages/express/src/serve.node.ts | 17 + packages/express/tsdown.config.ts | 8 + packages/fastify/package.json | 24 +- packages/fastify/src/apply-dev.ts | 15 - packages/fastify/src/apply-node.ts | 8 - packages/fastify/src/index.ts | 1 - packages/fastify/src/serve.node.ts | 42 +++ packages/fastify/tsdown.config.ts | 6 +- packages/h3/package.json | 2 +- packages/hattip/package.json | 2 +- packages/hono/package.json | 2 +- packages/runtime/package.json | 5 +- packages/runtime/src/vite.ts | 43 +++ packages/srvx/package.json | 2 +- pnpm-lock.yaml | 451 ++++++++++--------------- tests/app/fastify-entry.ts | 7 +- tests/app/package.json | 3 +- 27 files changed, 336 insertions(+), 334 deletions(-) create mode 100644 packages/express/src/serve.node.ts delete mode 100644 packages/fastify/src/apply-dev.ts delete mode 100644 packages/fastify/src/apply-node.ts create mode 100644 packages/fastify/src/serve.node.ts diff --git a/docs/package.json b/docs/package.json index 2db67997..186aac18 100644 --- a/docs/package.json +++ b/docs/package.json @@ -16,7 +16,7 @@ "react-dom": "^19.2.3", "typescript": "^5.9.3", "vike": "^0.4.249", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "type": "module", "version": null diff --git a/example/app-cloudflare/package.json b/example/app-cloudflare/package.json index ecf11322..2632aace 100644 --- a/example/app-cloudflare/package.json +++ b/example/app-cloudflare/package.json @@ -16,7 +16,7 @@ "e2e": "workspace:", "playwright": "^1.57.0", "typescript": "^5.9.3", - "vite": "^7.2.4", + "vite": "^7.3.1", "wrangler": "^4.56.0" }, "dependencies": { diff --git a/example/app-hono/package.json b/example/app-hono/package.json index 6754972e..8fe28c20 100644 --- a/example/app-hono/package.json +++ b/example/app-hono/package.json @@ -18,7 +18,7 @@ "e2e": "workspace:", "playwright": "^1.57.0", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "dependencies": { "@universal-middleware/core": "^0.4.14", diff --git a/example/app-netlify/package.json b/example/app-netlify/package.json index f560a465..fb056976 100644 --- a/example/app-netlify/package.json +++ b/example/app-netlify/package.json @@ -16,7 +16,7 @@ "e2e": "workspace:", "playwright": "^1.57.0", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "dependencies": { "@universal-middleware/core": "^0.4.14", diff --git a/example/app-vercel/package.json b/example/app-vercel/package.json index d4af1e9c..a740c418 100644 --- a/example/app-vercel/package.json +++ b/example/app-vercel/package.json @@ -15,7 +15,7 @@ "e2e": "workspace:", "playwright": "^1.57.0", "typescript": "^5.9.3", - "vite": "^7.2.4", + "vite": "^7.3.1", "wrangler": "^4.56.0" }, "dependencies": { diff --git a/example/awesome-framework/package.json b/example/awesome-framework/package.json index d421ff5e..519fe72b 100644 --- a/example/awesome-framework/package.json +++ b/example/awesome-framework/package.json @@ -16,7 +16,7 @@ "@types/node": "^22.19.1", "@universal-deploy/store": "^0.0.5", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "exports": { ".": "./dist/vite/index.js", diff --git a/example/tanstack-start/package.json b/example/tanstack-start/package.json index 57a252b3..e9c49495 100644 --- a/example/tanstack-start/package.json +++ b/example/tanstack-start/package.json @@ -36,7 +36,7 @@ "@vitejs/plugin-react": "^5.1.1", "jsdom": "^27.2.0", "typescript": "^5.9.3", - "vite": "^7.2.4", + "vite": "^7.3.1", "vitest": "^3.2.4", "web-vitals": "^5.1.0" }, diff --git a/packages/core/package.json b/packages/core/package.json index 3769fd95..b708d75b 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -51,7 +51,7 @@ "tsdown": "^0.18.1", "typescript": "^5.9.3", "unplugin": "^2.3.11", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/", diff --git a/packages/elysia/package.json b/packages/elysia/package.json index 8fe9a58c..354ba059 100644 --- a/packages/elysia/package.json +++ b/packages/elysia/package.json @@ -54,7 +54,7 @@ "elysia": "^1.4.19", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/" diff --git a/packages/express/package.json b/packages/express/package.json index f727d819..233c8e9a 100644 --- a/packages/express/package.json +++ b/packages/express/package.json @@ -6,7 +6,16 @@ "types": "./dist/index.d.ts", "exports": { ".": "./dist/index.js", - "./serve": "./dist/serve.js" + "./serve": { + "types": "./dist/serve.d.ts", + "workerd": "./dist/serve.js", + "worker": "./dist/serve.js", + "deno": "./dist/serve.node.js", + "bun": "./dist/serve.node.js", + "node": "./dist/serve.node.js", + "import": "./dist/serve.js", + "default": "./dist/serve.js" + } }, "scripts": { "dev": "tsdown --watch", @@ -29,9 +38,10 @@ "@types/node": "^22.19.1", "@universal-middleware/core": "^0.4.14", "express": "^5.2.1", + "srvx": "^0.9.8", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/" diff --git a/packages/express/src/serve.node.ts b/packages/express/src/serve.node.ts new file mode 100644 index 00000000..bd807b7e --- /dev/null +++ b/packages/express/src/serve.node.ts @@ -0,0 +1,17 @@ +import type { ServeReturn, ServerOptions } from "@photonjs/core/serve"; +import type { App as ExpressApp } from "@universal-middleware/express"; +import { toFetchHandler } from "srvx/node"; + +export function serve(app: App, options: ServerOptions = {}): ServeReturn { + return { + fetch: toFetchHandler(app), + server: { + name: "express", + app, + options, + get nodeHandler() { + return app; + }, + }, + }; +} diff --git a/packages/express/tsdown.config.ts b/packages/express/tsdown.config.ts index 00cd574d..d5dda288 100644 --- a/packages/express/tsdown.config.ts +++ b/packages/express/tsdown.config.ts @@ -20,6 +20,14 @@ export default defineConfig([ serve: "./src/serve.ts", }, }, + { + ...commonOptions, + platform: "node", + entry: { + // serve + "serve.node": "./src/serve.node.ts", + }, + }, { ...commonOptions, platform: "neutral", diff --git a/packages/fastify/package.json b/packages/fastify/package.json index e2b4e949..bd97c681 100644 --- a/packages/fastify/package.json +++ b/packages/fastify/package.json @@ -6,17 +6,16 @@ "types": "./dist/index.d.ts", "exports": { ".": "./dist/index.js", - "./apply": { - "types": "./dist/apply.d.ts", - "development": { - "types": "./dist/apply.dev.d.ts", - "import": "./dist/apply.dev.js", - "default": "./dist/apply.dev.js" - }, - "import": "./dist/apply.js", - "default": "./dist/apply.js" - }, - "./serve": "./dist/serve.js" + "./serve": { + "types": "./dist/serve.d.ts", + "workerd": "./dist/serve.js", + "worker": "./dist/serve.js", + "deno": "./dist/serve.node.js", + "bun": "./dist/serve.node.js", + "node": "./dist/serve.node.js", + "import": "./dist/serve.js", + "default": "./dist/serve.js" + } }, "scripts": { "dev": "tsdown --watch", @@ -40,9 +39,10 @@ "@universal-middleware/core": "^0.4.14", "ansis": "^4.2.0", "fastify": "^5.6.2", + "srvx": "^0.9.8", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/" diff --git a/packages/fastify/src/apply-dev.ts b/packages/fastify/src/apply-dev.ts deleted file mode 100644 index c8fdcf2c..00000000 --- a/packages/fastify/src/apply-dev.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:dev:fastify"; -import { createAsyncApply } from "@photonjs/core/apply"; -import { devServerMiddleware } from "@photonjs/core/dev"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/fastify"; - -export const apply = createAsyncApply( - "fastify", - applyAdapter, - getUniversalEntries, - getUniversalMiddlewares, - devServerMiddleware, -); - -export type RuntimeAdapter = RuntimeAdapterTarget<"fastify">; diff --git a/packages/fastify/src/apply-node.ts b/packages/fastify/src/apply-node.ts deleted file mode 100644 index 82a8f560..00000000 --- a/packages/fastify/src/apply-node.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { getUniversalEntries, getUniversalMiddlewares } from "virtual:photon:get-middlewares:node:fastify"; -import { createAsyncApply } from "@photonjs/core/apply"; -import type { RuntimeAdapterTarget } from "@universal-middleware/core"; -import { apply as applyAdapter } from "@universal-middleware/fastify"; - -export const apply = createAsyncApply("fastify", applyAdapter, getUniversalEntries, getUniversalMiddlewares); - -export type RuntimeAdapter = RuntimeAdapterTarget<"fastify">; diff --git a/packages/fastify/src/index.ts b/packages/fastify/src/index.ts index 1565e14d..83cf7ba8 100644 --- a/packages/fastify/src/index.ts +++ b/packages/fastify/src/index.ts @@ -1,2 +1 @@ -export { apply, type RuntimeAdapter } from "@photonjs/fastify/apply"; export { serve } from "@photonjs/fastify/serve"; diff --git a/packages/fastify/src/serve.node.ts b/packages/fastify/src/serve.node.ts new file mode 100644 index 00000000..8bbe9f42 --- /dev/null +++ b/packages/fastify/src/serve.node.ts @@ -0,0 +1,42 @@ +import type { IncomingMessage, ServerResponse } from "node:http"; +import type { NodeHandler, ServeReturn, ServerOptionsBase } from "@photonjs/core/serve"; +import type { App as FastifyApp } from "@universal-middleware/fastify"; +import { bold, yellow } from "ansis"; +import { toFetchHandler } from "srvx/node"; + +export function serve(app: App, options: ServerOptionsBase = {}): ServeReturn { + if (import.meta.hot) { + const optionsSymbol = Object.getOwnPropertySymbols(app).find((s) => s.toString() === "Symbol(fastify.options)"); + // biome-ignore lint/suspicious/noExplicitAny: any + const appAny = app as Record; + + if (optionsSymbol && !appAny[optionsSymbol]?.forceCloseConnections) { + console.warn( + yellow( + `${bold("[photon:fastify]")} Please make sure that fastify is initialized with \`{ forceCloseConnections: true }\` for proper HMR support.`, + ), + ); + } + } + + let nodeHandler: NodeHandler = (req, res) => { + app.ready().then(() => { + // cache handler once ready + nodeHandler = app.routing as NodeHandler; + app.routing(req as IncomingMessage, res as ServerResponse); + }); + }; + + return { + // biome-ignore lint/suspicious/noExplicitAny: cast + fetch: toFetchHandler(nodeHandler as any), + server: { + name: "fastify", + app, + options, + get nodeHandler() { + return nodeHandler; + }, + }, + }; +} diff --git a/packages/fastify/tsdown.config.ts b/packages/fastify/tsdown.config.ts index 014bdf91..7e482f60 100644 --- a/packages/fastify/tsdown.config.ts +++ b/packages/fastify/tsdown.config.ts @@ -24,10 +24,8 @@ export default defineConfig([ ...commonOptions, platform: "node", entry: { - // apply (dev) - "apply.dev": "./src/apply-dev.ts", - // apply (node) - apply: "./src/apply-node.ts", + // serve + "serve.node": "./src/serve.node.ts", }, }, { diff --git a/packages/h3/package.json b/packages/h3/package.json index 29baa607..1a0da744 100644 --- a/packages/h3/package.json +++ b/packages/h3/package.json @@ -53,7 +53,7 @@ "h3": "^1.15.4", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/" diff --git a/packages/hattip/package.json b/packages/hattip/package.json index 0bfda083..048b4094 100644 --- a/packages/hattip/package.json +++ b/packages/hattip/package.json @@ -32,7 +32,7 @@ "@universal-middleware/core": "^0.4.14", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/" diff --git a/packages/hono/package.json b/packages/hono/package.json index 69fac3b7..a1cbcda9 100644 --- a/packages/hono/package.json +++ b/packages/hono/package.json @@ -41,7 +41,7 @@ "@universal-middleware/core": "^0.4.14", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/" diff --git a/packages/runtime/package.json b/packages/runtime/package.json index fb35c52f..0cf33212 100644 --- a/packages/runtime/package.json +++ b/packages/runtime/package.json @@ -22,9 +22,10 @@ }, "dependencies": { "@photonjs/srvx": "workspace:^", + "@universal-deploy/node": "^0.0.1", + "@universal-deploy/store": "^0.0.5", "@universal-middleware/core": "^0.4.14", "@universal-middleware/sirv": "^0.1.24", - "@universal-deploy/node": "^0.0.1", "srvx": "^0.9.8", "standaloner": "^0.1.11" }, @@ -40,7 +41,7 @@ "@types/node": "^22.19.1", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/", diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index 5637cbba..20a190da 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -1,5 +1,8 @@ import type { Plugin } from "vite"; +const re_enhanced = /[?&]enhanced\b/; +const re_catchAll = /^virtual:ud:catch-all\?default$/; + // Creates a server and listens for connections in Node/Deno/Bun export function serve(): Plugin[] { let userPort: number | undefined; @@ -26,6 +29,46 @@ export function serve(): Plugin[] { }, }, }, + { + name: "photon:wrap-enhance", + enforce: "pre", + + resolveId: { + filter: { + id: [re_enhanced, /^virtual:ud:catch-all\?default$/], + }, + async handler(id, importer) { + if (importer?.match(re_enhanced)) return; + if (id.match(re_catchAll)) { + const resolved = await this.resolve(id, importer, { skipSelf: true }); + if (resolved) { + return `\0${resolved.id}&enhanced`; + } + } + return `\0${id}`; + }, + }, + load: { + filter: { + id: [/^\0.*[?&]enhanced\b/], + }, + // TODO create an util in UM to compile enhance + async handler(id) { + const wrappedModule = id.slice(1).replace(re_enhanced, ""); + + if (!wrappedModule.match(re_catchAll)) { + this.warn('?enhanced only supported by "virtual:ud:catch-all?default"'); + return; + } + + return `import mod from ${JSON.stringify(wrappedModule)}; +mod.fetch[Symbol.for("unPath")] = ${JSON.stringify("/**")}; +mod.fetch[Symbol.for("unMethod")] = ${JSON.stringify("GET")}; +export default mod; + `; + }, + }, + }, { name: "photon:serve:transform-dev", apply: "serve", diff --git a/packages/srvx/package.json b/packages/srvx/package.json index 37e10778..1078c8f6 100644 --- a/packages/srvx/package.json +++ b/packages/srvx/package.json @@ -53,7 +53,7 @@ "srvx": "^0.9.8", "tsdown": "^0.18.1", "typescript": "^5.9.3", - "vite": "^7.2.4" + "vite": "^7.3.1" }, "files": [ "dist/" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 41a4de35..54ed333c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -31,7 +31,7 @@ importers: dependencies: '@brillout/docpress': specifier: ^0.16.2 - version: 0.16.2(@algolia/client-search@5.40.0)(@types/react@19.2.7)(@vitejs/plugin-react-swc@4.2.2(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(rollup@4.53.5)(search-insights@2.17.3)(typescript@5.9.3)(vike@0.4.249(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 0.16.2(@algolia/client-search@5.40.0)(@types/react@19.2.7)(@vitejs/plugin-react-swc@4.2.2(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(rollup@4.53.5)(search-insights@2.17.3)(typescript@5.9.3)(vike@0.4.249(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@types/node': specifier: ^22.19.1 version: 22.19.1 @@ -43,7 +43,7 @@ importers: version: 19.2.3(@types/react@19.2.7) '@vitejs/plugin-react-swc': specifier: ^4.2.2 - version: 4.2.2(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 4.2.2(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) react: specifier: ^19.2.3 version: 19.2.3 @@ -55,16 +55,16 @@ importers: version: 5.9.3 vike: specifier: ^0.4.249 - version: 0.4.249(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 0.4.249(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) example/app-cloudflare: dependencies: '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -91,17 +91,17 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) wrangler: specifier: ^4.56.0 - version: 4.56.0(@cloudflare/workers-types@4.20251219.0) + version: 4.56.0 example/app-hono: dependencies: '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -128,14 +128,14 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) example/app-netlify: dependencies: '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -156,14 +156,14 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) example/app-vercel: dependencies: '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -176,7 +176,7 @@ importers: version: link:../../packages/runtime '@photonjs/vercel': specifier: ^0.1.22 - version: 0.1.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(rollup@4.53.5)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 0.1.22(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(rollup@4.53.5)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) e2e: specifier: 'workspace:' version: link:../../tests/e2e @@ -187,11 +187,11 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) wrangler: specifier: ^4.56.0 - version: 4.56.0(@cloudflare/workers-types@4.20251219.0) + version: 4.56.0 example/awesome-framework: dependencies: @@ -203,7 +203,7 @@ importers: version: link:../../packages/runtime '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': specifier: ^0.1.24 version: 0.1.24 @@ -213,25 +213,25 @@ importers: version: 22.19.1 '@universal-deploy/store': specifier: ^0.0.5 - version: 0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) typescript: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) example/tanstack-start: dependencies: '@photonjs/cloudflare': specifier: ^0.1.13 - version: 0.1.13(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0)) + version: 0.1.13(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0) '@photonjs/runtime': specifier: ^0.1.16 version: link:../../packages/runtime '@tailwindcss/vite': specifier: ^4.1.17 - version: 4.1.17(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 4.1.17(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@tanstack/react-devtools': specifier: ^0.7.11 version: 0.7.11(@types/react-dom@19.2.3(@types/react@19.2.7))(@types/react@19.2.7)(csstype@3.2.3)(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(solid-js@1.9.10) @@ -246,10 +246,10 @@ importers: version: 1.139.0(@tanstack/query-core@5.90.10)(@tanstack/react-query@5.90.10(react@19.2.3))(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(@tanstack/router-core@1.139.0)(react-dom@19.2.3(react@19.2.3))(react@19.2.3) '@tanstack/react-start': specifier: ^1.139.0 - version: 1.139.0(crossws@0.4.1(srvx@0.9.8))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 1.139.0(crossws@0.4.1(srvx@0.9.8))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@tanstack/router-plugin': specifier: ^1.139.0 - version: 1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) lucide-react: specifier: ^0.554.0 version: 0.554.0(react@19.2.3) @@ -264,11 +264,11 @@ importers: version: 4.1.17 vite-tsconfig-paths: specifier: ^5.1.4 - version: 5.1.4(typescript@5.9.3)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 5.1.4(typescript@5.9.3)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) devDependencies: '@tanstack/devtools-vite': specifier: ^0.3.11 - version: 0.3.11(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 0.3.11(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@testing-library/dom': specifier: ^10.4.1 version: 10.4.1 @@ -286,7 +286,7 @@ importers: version: 19.2.3(@types/react@19.2.7) '@vitejs/plugin-react': specifier: ^5.1.1 - version: 5.1.1(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 5.1.1(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) jsdom: specifier: ^27.2.0 version: 27.2.0 @@ -294,8 +294,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) vitest: specifier: ^3.2.4 version: 3.2.4(@edge-runtime/vm@3.2.0)(@types/debug@4.1.12)(@types/node@22.19.1)(jiti@2.6.1)(jsdom@27.2.0)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) @@ -310,16 +310,16 @@ importers: version: 0.7.15 '@universal-middleware/cloudflare': specifier: ^0.4.10 - version: 0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) '@universal-middleware/compress': specifier: ^0.2.34 version: 0.2.34 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/express': specifier: ^0.4.22 - version: 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': specifier: ^0.1.24 version: 0.1.24 @@ -361,8 +361,8 @@ importers: specifier: ^2.3.11 version: 2.3.11 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/elysia: dependencies: @@ -371,7 +371,7 @@ importers: version: link:../core '@universal-middleware/elysia': specifier: ^0.6.2 - version: 0.6.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.6.2(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) devDependencies: '@elysiajs/node': specifier: ^1.4.2 @@ -387,7 +387,7 @@ importers: version: 22.19.1 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) elysia: specifier: ^1.4.19 version: 1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3) @@ -398,8 +398,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/express: dependencies: @@ -408,17 +408,20 @@ importers: version: link:../core '@universal-middleware/express': specifier: ^0.4.22 - version: 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) devDependencies: '@types/node': specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) express: specifier: ^5.2.1 version: 5.2.1 + srvx: + specifier: ^0.9.8 + version: 0.9.8 tsdown: specifier: ^0.18.1 version: 0.18.1(typescript@5.9.3) @@ -426,8 +429,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/fastify: dependencies: @@ -436,20 +439,23 @@ importers: version: link:../core '@universal-middleware/fastify': specifier: ^0.5.22 - version: 0.5.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.5.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) devDependencies: '@types/node': specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) ansis: specifier: ^4.2.0 version: 4.2.0 fastify: specifier: ^5.6.2 version: 5.6.2 + srvx: + specifier: ^0.9.8 + version: 0.9.8 tsdown: specifier: ^0.18.1 version: 0.18.1(typescript@5.9.3) @@ -457,8 +463,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/h3: dependencies: @@ -467,7 +473,7 @@ importers: version: link:../core '@universal-middleware/h3': specifier: ^0.4.15 - version: 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) devDependencies: '@types/bun': specifier: ^1.3.3 @@ -480,7 +486,7 @@ importers: version: 22.19.1 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) h3: specifier: ^1.15.4 version: 1.15.4 @@ -491,8 +497,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/hattip: dependencies: @@ -501,7 +507,7 @@ importers: version: link:../core '@universal-middleware/hattip': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) devDependencies: '@types/bun': specifier: ^1.3.3 @@ -514,7 +520,7 @@ importers: version: 22.19.1 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) tsdown: specifier: ^0.18.1 version: 0.18.1(typescript@5.9.3) @@ -522,14 +528,14 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/hono: dependencies: '@universal-middleware/hono': specifier: ^0.4.18 - version: 0.4.18(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.20(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) devDependencies: '@hono/node-server': specifier: ^1.19.7 @@ -545,7 +551,7 @@ importers: version: 22.19.1 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) tsdown: specifier: ^0.18.1 version: 0.18.1(typescript@5.9.3) @@ -553,8 +559,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/runtime: dependencies: @@ -563,10 +569,13 @@ importers: version: link:../srvx '@universal-deploy/node': specifier: ^0.0.1 - version: 0.0.1(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 0.0.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@universal-deploy/store': + specifier: ^0.0.5 + version: 0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': specifier: ^0.1.24 version: 0.1.24 @@ -587,8 +596,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) packages/srvx: dependencies: @@ -597,7 +606,7 @@ importers: version: link:../core '@universal-middleware/srvx': specifier: ^0.1.1 - version: 0.1.1(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.1.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) devDependencies: '@types/bun': specifier: ^1.3.3 @@ -610,7 +619,7 @@ importers: version: 22.19.1 '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) srvx: specifier: ^0.9.8 version: 0.9.8 @@ -621,8 +630,8 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) tests/app: dependencies: @@ -631,7 +640,10 @@ importers: version: 0.0.49 '@universal-middleware/express': specifier: ^0.4.23 - version: 0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/fastify': + specifier: ^0.5.23 + version: 0.5.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/hattip': specifier: ^0.4.15 version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -695,10 +707,10 @@ importers: version: 22.19.1 '@universal-deploy/store': specifier: ^0.0.5 - version: 0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/core': specifier: ^0.4.14 - version: 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) pkg-types: specifier: ^2.3.0 version: 2.3.0 @@ -706,11 +718,11 @@ importers: specifier: ^5.9.3 version: 5.9.3 vite: - specifier: ^7.2.4 - version: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + specifier: ^7.3.1 + version: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) wrangler: specifier: ^4.56.0 - version: 4.56.0(@cloudflare/workers-types@4.20251219.0) + version: 4.56.0 tests/e2e: dependencies: @@ -1167,9 +1179,6 @@ packages: cpu: [x64] os: [win32] - '@cloudflare/workers-types@4.20251219.0': - resolution: {integrity: sha512-qwuvc3ZDdCfcK9dJrBSFHOsX8kL72sypfBilzEWbbb+slB2NiggjsHeGMV2ZQiQc1zyBMQPjIvsVeE7Apxp7hw==} - '@cspotcode/source-map-support@0.8.1': resolution: {integrity: sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==} engines: {node: '>=12'} @@ -3004,38 +3013,6 @@ packages: '@universal-middleware/compress@0.2.34': resolution: {integrity: sha512-zpLaiHHEfx1ouahZ+NKc5UScsiRAsEn+wiwWMH55JAEeUQ73zymw3e1kZg45Tr/oQh8X3PL0YrRKXDdc5Lt8WA==} - '@universal-middleware/core@0.4.14': - resolution: {integrity: sha512-yomLeaMdh0YYnIWA5wt71+znX1oTf+olO+XnsvEEids8FexxsAxyjkjGaIeRYr4Vc5CviKEriTe6ewkpLRtdgQ==} - peerDependencies: - '@cloudflare/workers-types': ^4.20251213.0 - '@hattip/core': ^0.0.49 - '@types/express': ^4 || ^5 - '@webroute/route': ^0.8.0 - elysia: ^1.4.19 - fastify: ^5.6.2 - h3: ^1.15.4 - hono: ^4.11.1 - srvx: ^0.8 || ^0.9 - peerDependenciesMeta: - '@cloudflare/workers-types': - optional: true - '@hattip/core': - optional: true - '@types/express': - optional: true - '@webroute/route': - optional: true - elysia: - optional: true - fastify: - optional: true - h3: - optional: true - hono: - optional: true - srvx: - optional: true - '@universal-middleware/core@0.4.15': resolution: {integrity: sha512-4nUc79ANoExxldCGz4b2ttyxjopcmO8MH7sbJLCvFKxa9DdbHfsXI9+HAvgbKAYqC8FAFbadsMzqnAeSqis1dw==} peerDependencies: @@ -3071,27 +3048,18 @@ packages: '@universal-middleware/elysia@0.6.2': resolution: {integrity: sha512-2sYpGd07iHqiyezCtWX7JB36Cd33kIIaferkm/CiAlTqx/N5tjK0rg3ounY1BWnezcluqSe1lBQu8JztJ/dSWQ==} - '@universal-middleware/express@0.4.22': - resolution: {integrity: sha512-4aIrnK52NJmYKokZnwpWja/vT2m/HoZ8zxQyYLdokkSQdx0B1k1VsmYGeWENvpDQBgLjnfyvDzyaxch6Tib/hA==} - '@universal-middleware/express@0.4.23': resolution: {integrity: sha512-wFM9HQWIXrK+CJvld95bwkGbb1wA/bKkwBBKI5njPShVCMayFoSDb6FMrqezHqI3hGBcjUs9D17CVIJa6gzdPA==} - '@universal-middleware/fastify@0.5.22': - resolution: {integrity: sha512-6axgXhhi69V4RHh6DjUxRmWnRN8U9cW/Ro/1lB0weTe4Y07pI/9603XGcg9iNltbqEhjRvK+Jch3WwwIfVdIBg==} + '@universal-middleware/fastify@0.5.23': + resolution: {integrity: sha512-4XnVUv6by1OI5M3kzDqYCPYc1W8cMBEXGKbD33mojgC81FnkPTUoPrFmw+zzfTsgLx7JqsTOx/Qf/5VAWNa9GQ==} '@universal-middleware/h3@0.4.15': resolution: {integrity: sha512-IdoQ9cHSQEh7R1MtUppstuOrKLo//6hFv1AdVx0fyqCOELk0+rGH63VJ2MjnA26/xqysqrbjkiNQilBucAyfxw==} - '@universal-middleware/hattip@0.4.14': - resolution: {integrity: sha512-8goLMiH5TeDLjNF8687j+GxWnokfq0dMSfEJjWT9BvvRmyMs4p42UztewPx103xjgOw9BO5fGBKu4Fmq0I5FBw==} - '@universal-middleware/hattip@0.4.15': resolution: {integrity: sha512-uBGMSN2hTdmkpWH8jt/UKGGXpJJhSBnXp/0HQRuzhZs3Ip2ubtX5K8/Iq/cAA2AG3ZYJA19+vo6+86to5ZiujA==} - '@universal-middleware/hono@0.4.18': - resolution: {integrity: sha512-RpnX8hKh2zx7hwVYzI32DjvH7KBYpt7MLIHWYw9QBSEzpD1ErqL+SpkvvlJaINjFs+sYJKH5IOoL53uHCL5alw==} - '@universal-middleware/hono@0.4.20': resolution: {integrity: sha512-UYsp/urka7BEilzAn/SlnDNxel5rWKV+hRDqwoPhq3E1bJ91M6YuT5OR4EtTm2Jx4S0fFMr8ITA2F4hWZ/+vgw==} @@ -5763,8 +5731,8 @@ packages: vite: optional: true - vite@7.2.4: - resolution: {integrity: sha512-NL8jTlbo0Tn4dUEXEsUg8KeyG/Lkmc4Fnzb8JXN/Ykm9G4HNImjtABMJgkQoVjOBN/j2WAwDTRytdqJbZsah7w==} + vite@7.3.1: + resolution: {integrity: sha512-w+N7Hifpc3gRjZ63vYBXA56dvvRlNWRczTdmCBBa+CotUzAPf5b7YMdMR/8CQoeYE5LX3W4wj6RYTgonm1b9DA==} engines: {node: ^20.19.0 || >=22.12.0} hasBin: true peerDependencies: @@ -6371,7 +6339,7 @@ snapshots: '@borewit/text-codec@0.1.1': {} - '@brillout/docpress@0.16.2(@algolia/client-search@5.40.0)(@types/react@19.2.7)(@vitejs/plugin-react-swc@4.2.2(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(rollup@4.53.5)(search-insights@2.17.3)(typescript@5.9.3)(vike@0.4.249(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@brillout/docpress@0.16.2(@algolia/client-search@5.40.0)(@types/react@19.2.7)(@vitejs/plugin-react-swc@4.2.2(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(rollup@4.53.5)(search-insights@2.17.3)(typescript@5.9.3)(vike@0.4.249(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)))(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@brillout/picocolors': 1.0.29 '@docsearch/css': 3.9.0 @@ -6388,10 +6356,10 @@ snapshots: shiki: 1.2.0 typescript: 5.9.3 unist-util-visit: 5.0.0 - vike: 0.4.249(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + vike: 0.4.249(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) optionalDependencies: - '@vitejs/plugin-react-swc': 4.2.2(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + '@vitejs/plugin-react-swc': 4.2.2(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - '@algolia/client-search' - '@types/react' @@ -6583,7 +6551,7 @@ snapshots: optionalDependencies: workerd: 1.20251217.0 - '@cloudflare/vite-plugin@1.19.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0))': + '@cloudflare/vite-plugin@1.19.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0)': dependencies: '@cloudflare/unenv-preset': 2.7.13(unenv@2.0.0-rc.24)(workerd@1.20251217.0) '@remix-run/node-fetch-server': 0.8.1 @@ -6593,8 +6561,8 @@ snapshots: picocolors: 1.1.1 tinyglobby: 0.2.15 unenv: 2.0.0-rc.24 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - wrangler: 4.56.0(@cloudflare/workers-types@4.20251219.0) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + wrangler: 4.56.0 ws: 8.18.0 transitivePeerDependencies: - bufferutil @@ -6616,9 +6584,6 @@ snapshots: '@cloudflare/workerd-windows-64@1.20251217.0': optional: true - '@cloudflare/workers-types@4.20251219.0': - optional: true - '@cspotcode/source-map-support@0.8.1': dependencies: '@jridgewell/trace-mapping': 0.3.9 @@ -7283,11 +7248,11 @@ snapshots: '@oxc-project/types@0.98.0': {} - '@photonjs/cloudflare@0.1.13(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0))': + '@photonjs/cloudflare@0.1.13(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0)': dependencies: - '@cloudflare/vite-plugin': 1.19.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0)) - '@photonjs/core': 0.1.21(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) - '@universal-middleware/cloudflare': 0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@cloudflare/vite-plugin': 1.19.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0) + '@photonjs/core': 0.1.21(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@universal-middleware/cloudflare': 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -7304,19 +7269,19 @@ snapshots: - workerd - wrangler - '@photonjs/core@0.1.21(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@photonjs/core@0.1.21(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@brillout/vite-plugin-server-entry': 0.7.15 - '@universal-middleware/cloudflare': 0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/cloudflare': 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) '@universal-middleware/compress': 0.2.34 - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/express': 0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/express': 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': 0.1.24 estree-walker: 3.0.3 ts-deepmerge: 7.0.3 zod: 4.2.1 optionalDependencies: - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -7328,14 +7293,14 @@ snapshots: - hono - srvx - '@photonjs/vercel@0.1.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(rollup@4.53.5)(srvx@0.9.8)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@photonjs/vercel@0.1.22(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(rollup@4.53.5)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@brillout/libassert': 0.5.8 '@manypkg/find-root': 3.1.0 '@photonjs/core': link:packages/core '@photonjs/runtime': link:packages/runtime - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/vercel': 0.4.29(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/vercel': 0.4.29(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) '@vercel/build-utils': 13.2.4 '@vercel/nft': 1.1.1(rollup@4.53.5) '@vercel/routing-utils': 5.3.1 @@ -7346,8 +7311,8 @@ snapshots: magicast: 0.5.1 path-to-regexp: 8.3.0 strip-ansi: 7.1.2 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - vite-plugin-wasm: 3.5.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite-plugin-wasm: 3.5.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -7719,12 +7684,12 @@ snapshots: '@tailwindcss/oxide-win32-arm64-msvc': 4.1.17 '@tailwindcss/oxide-win32-x64-msvc': 4.1.17 - '@tailwindcss/vite@4.1.17(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@tailwindcss/vite@4.1.17(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@tailwindcss/node': 4.1.17 '@tailwindcss/oxide': 4.1.17 tailwindcss: 4.1.17 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) '@tanstack/devtools-client@0.0.3': dependencies: @@ -7751,7 +7716,7 @@ snapshots: transitivePeerDependencies: - csstype - '@tanstack/devtools-vite@0.3.11(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@tanstack/devtools-vite@0.3.11(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@babel/core': 7.28.5 '@babel/generator': 7.28.5 @@ -7763,7 +7728,7 @@ snapshots: chalk: 5.6.2 launch-editor: 2.12.0 picomatch: 4.0.3 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - bufferutil - supports-color @@ -7785,7 +7750,7 @@ snapshots: - csstype - utf-8-validate - '@tanstack/directive-functions-plugin@1.139.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@tanstack/directive-functions-plugin@1.139.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@babel/code-frame': 7.27.1 '@babel/core': 7.28.5 @@ -7795,7 +7760,7 @@ snapshots: babel-dead-code-elimination: 1.0.10 pathe: 2.0.3 tiny-invariant: 1.3.3 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - supports-color @@ -7827,7 +7792,7 @@ snapshots: '@tanstack/router-devtools-core': 1.139.0(@tanstack/router-core@1.139.0)(@types/node@22.19.1)(csstype@3.2.3)(jiti@2.6.1)(lightningcss@1.30.2)(solid-js@1.9.10)(tsx@4.20.6)(yaml@2.8.2) react: 19.2.3 react-dom: 19.2.3(react@19.2.3) - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) optionalDependencies: '@tanstack/router-core': 1.139.0 transitivePeerDependencies: @@ -7889,19 +7854,19 @@ snapshots: transitivePeerDependencies: - crossws - '@tanstack/react-start@1.139.0(crossws@0.4.1(srvx@0.9.8))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@tanstack/react-start@1.139.0(crossws@0.4.1(srvx@0.9.8))(react-dom@19.2.3(react@19.2.3))(react@19.2.3)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@tanstack/react-router': 1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3) '@tanstack/react-start-client': 1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3) '@tanstack/react-start-server': 1.139.0(crossws@0.4.1(srvx@0.9.8))(react-dom@19.2.3(react@19.2.3))(react@19.2.3) '@tanstack/router-utils': 1.139.0 '@tanstack/start-client-core': 1.139.0 - '@tanstack/start-plugin-core': 1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(crossws@0.4.1(srvx@0.9.8))(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@tanstack/start-plugin-core': 1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(crossws@0.4.1(srvx@0.9.8))(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@tanstack/start-server-core': 1.139.0(crossws@0.4.1(srvx@0.9.8)) pathe: 2.0.3 react: 19.2.3 react-dom: 19.2.3(react@19.2.3) - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - '@rsbuild/core' - crossws @@ -7933,7 +7898,7 @@ snapshots: goober: 2.1.18(csstype@3.2.3) solid-js: 1.9.10 tiny-invariant: 1.3.3 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) optionalDependencies: csstype: 3.2.3 transitivePeerDependencies: @@ -7962,7 +7927,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@tanstack/router-plugin@1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@tanstack/router-plugin@1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@babel/core': 7.28.5 '@babel/plugin-syntax-jsx': 7.27.1(@babel/core@7.28.5) @@ -7980,7 +7945,7 @@ snapshots: zod: 3.25.76 optionalDependencies: '@tanstack/react-router': 1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3) - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - supports-color @@ -8002,7 +7967,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@tanstack/server-functions-plugin@1.139.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@tanstack/server-functions-plugin@1.139.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@babel/code-frame': 7.27.1 '@babel/core': 7.28.5 @@ -8011,7 +7976,7 @@ snapshots: '@babel/template': 7.27.2 '@babel/traverse': 7.28.5 '@babel/types': 7.28.5 - '@tanstack/directive-functions-plugin': 1.139.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@tanstack/directive-functions-plugin': 1.139.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) babel-dead-code-elimination: 1.0.10 tiny-invariant: 1.3.3 transitivePeerDependencies: @@ -8026,7 +7991,7 @@ snapshots: tiny-invariant: 1.3.3 tiny-warning: 1.0.3 - '@tanstack/start-plugin-core@1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(crossws@0.4.1(srvx@0.9.8))(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@tanstack/start-plugin-core@1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(crossws@0.4.1(srvx@0.9.8))(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@babel/code-frame': 7.26.2 '@babel/core': 7.28.5 @@ -8034,9 +7999,9 @@ snapshots: '@rolldown/pluginutils': 1.0.0-beta.40 '@tanstack/router-core': 1.139.0 '@tanstack/router-generator': 1.139.0 - '@tanstack/router-plugin': 1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@tanstack/router-plugin': 1.139.0(@tanstack/react-router@1.139.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3))(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@tanstack/router-utils': 1.139.0 - '@tanstack/server-functions-plugin': 1.139.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@tanstack/server-functions-plugin': 1.139.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@tanstack/start-client-core': 1.139.0 '@tanstack/start-server-core': 1.139.0(crossws@0.4.1(srvx@0.9.8)) babel-dead-code-elimination: 1.0.10 @@ -8046,8 +8011,8 @@ snapshots: srvx: 0.8.16 tinyglobby: 0.2.15 ufo: 1.6.1 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - vitefu: 1.1.1(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vitefu: 1.1.1(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) xmlbuilder2: 4.0.0 zod: 3.25.76 transitivePeerDependencies: @@ -8229,13 +8194,13 @@ snapshots: '@ungap/structured-clone@1.3.0': {} - '@universal-deploy/node@0.0.1(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@universal-deploy/node@0.0.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: - '@universal-deploy/store': 0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-deploy/store': 0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': 0.1.24 srvx: 0.9.8 optionalDependencies: - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8246,9 +8211,9 @@ snapshots: - h3 - hono - '@universal-deploy/store@0.0.5(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-deploy/store@0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/express': 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) rou3: 0.7.12 transitivePeerDependencies: - '@cloudflare/workers-types' @@ -8261,9 +8226,9 @@ snapshots: - hono - srvx - '@universal-middleware/cloudflare@0.4.10(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/cloudflare@0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8277,26 +8242,11 @@ snapshots: '@universal-middleware/compress@0.2.34': {} - '@universal-middleware/core@0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': - dependencies: - regexparam: 3.0.0 - tough-cookie: 6.0.0 - optionalDependencies: - '@cloudflare/workers-types': 4.20251219.0 - '@hattip/core': 0.0.49 - '@types/express': 5.0.6 - elysia: 1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3) - fastify: 5.6.2 - h3: 1.15.4 - hono: 4.11.1 - srvx: 0.9.8 - - '@universal-middleware/core@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/core@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: regexparam: 3.0.0 tough-cookie: 6.0.0 optionalDependencies: - '@cloudflare/workers-types': 4.20251219.0 '@hattip/core': 0.0.49 '@types/express': 5.0.6 elysia: 1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3) @@ -8305,23 +8255,9 @@ snapshots: hono: 4.11.1 srvx: 0.9.8 - '@universal-middleware/elysia@0.6.2(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': - dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - transitivePeerDependencies: - - '@cloudflare/workers-types' - - '@hattip/core' - - '@types/express' - - '@webroute/route' - - elysia - - fastify - - h3 - - hono - - srvx - - '@universal-middleware/express@0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/elysia@0.6.2(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8333,9 +8269,9 @@ snapshots: - hono - srvx - '@universal-middleware/express@0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/express@0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8347,10 +8283,10 @@ snapshots: - hono - srvx - '@universal-middleware/fastify@0.5.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/fastify@0.5.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/express': 0.4.22(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/express': 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) fastify-raw-body: 5.0.0 transitivePeerDependencies: - '@cloudflare/workers-types' @@ -8363,23 +8299,9 @@ snapshots: - hono - srvx - '@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': - dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - transitivePeerDependencies: - - '@cloudflare/workers-types' - - '@hattip/core' - - '@types/express' - - '@webroute/route' - - elysia - - fastify - - h3 - - hono - - srvx - - '@universal-middleware/hattip@0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8393,21 +8315,7 @@ snapshots: '@universal-middleware/hattip@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - transitivePeerDependencies: - - '@cloudflare/workers-types' - - '@hattip/core' - - '@types/express' - - '@webroute/route' - - elysia - - fastify - - h3 - - hono - - srvx - - '@universal-middleware/hono@0.4.18(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': - dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8421,7 +8329,7 @@ snapshots: '@universal-middleware/hono@0.4.20(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8438,9 +8346,9 @@ snapshots: mrmime: 2.0.1 totalist: 3.0.1 - '@universal-middleware/srvx@0.1.1(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/srvx@0.1.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.14(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8452,18 +8360,16 @@ snapshots: - hono - srvx - '@universal-middleware/vercel@0.4.29(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8))(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/vercel@0.4.29(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/express': 0.4.23(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/express': 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) optionalDependencies: '@hattip/core': 0.0.49 - '@universal-middleware/h3': 0.4.15(@cloudflare/workers-types@4.20251219.0)(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - elysia: 1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3) + '@universal-middleware/h3': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) express: 5.2.1 fastify: 5.6.2 h3: 1.15.4 - hono: 4.11.1 srvx: 0.9.8 transitivePeerDependencies: - '@cloudflare/workers-types' @@ -8525,15 +8431,15 @@ snapshots: dependencies: zod: 4.2.1 - '@vitejs/plugin-react-swc@4.2.2(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@vitejs/plugin-react-swc@4.2.2(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@rolldown/pluginutils': 1.0.0-beta.47 '@swc/core': 1.13.5 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - '@swc/helpers' - '@vitejs/plugin-react@5.1.1(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@vitejs/plugin-react@5.1.1(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@babel/core': 7.28.5 '@babel/plugin-transform-react-jsx-self': 7.27.1(@babel/core@7.28.5) @@ -8541,7 +8447,7 @@ snapshots: '@rolldown/pluginutils': 1.0.0-beta.47 '@types/babel__core': 7.20.5 react-refresh: 0.18.0 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - supports-color @@ -8553,13 +8459,13 @@ snapshots: chai: 5.3.3 tinyrainbow: 2.0.0 - '@vitest/mocker@3.2.4(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@vitest/mocker@3.2.4(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@vitest/spy': 3.2.4 estree-walker: 3.0.3 magic-string: 0.30.21 optionalDependencies: - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) '@vitest/pretty-format@3.2.4': dependencies: @@ -11780,7 +11686,7 @@ snapshots: '@types/unist': 3.0.3 vfile-message: 4.0.3 - vike@0.4.249(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): + vike@0.4.249(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): dependencies: '@brillout/import': 0.2.6 '@brillout/json-serializer': 0.5.21 @@ -11799,7 +11705,7 @@ snapshots: source-map-support: 0.5.21 tinyglobby: 0.2.15 optionalDependencies: - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) vite-node@3.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2): dependencies: @@ -11807,7 +11713,7 @@ snapshots: debug: 4.4.3 es-module-lexer: 1.7.0 pathe: 2.0.3 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - '@types/node' - jiti @@ -11822,24 +11728,24 @@ snapshots: - tsx - yaml - vite-plugin-wasm@3.5.0(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): + vite-plugin-wasm@3.5.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): dependencies: - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) - vite-tsconfig-paths@5.1.4(typescript@5.9.3)(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): + vite-tsconfig-paths@5.1.4(typescript@5.9.3)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): dependencies: debug: 4.4.3 globrex: 0.1.2 tsconfck: 3.1.6(typescript@5.9.3) optionalDependencies: - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) transitivePeerDependencies: - supports-color - typescript - vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2): + vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2): dependencies: - esbuild: 0.25.12 + esbuild: 0.27.2 fdir: 6.5.0(picomatch@4.0.3) picomatch: 4.0.3 postcss: 8.5.6 @@ -11853,15 +11759,15 @@ snapshots: tsx: 4.20.6 yaml: 2.8.2 - vitefu@1.1.1(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): + vitefu@1.1.1(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)): optionalDependencies: - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) vitest@3.2.4(@edge-runtime/vm@3.2.0)(@types/debug@4.1.12)(@types/node@22.19.1)(jiti@2.6.1)(jsdom@27.2.0)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2): dependencies: '@types/chai': 5.2.3 '@vitest/expect': 3.2.4 - '@vitest/mocker': 3.2.4(vite@7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@vitest/mocker': 3.2.4(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@vitest/pretty-format': 3.2.4 '@vitest/runner': 3.2.4 '@vitest/snapshot': 3.2.4 @@ -11879,7 +11785,7 @@ snapshots: tinyglobby: 0.2.15 tinypool: 1.1.1 tinyrainbow: 2.0.0 - vite: 7.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) + vite: 7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) vite-node: 3.2.4(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2) why-is-node-running: 2.3.0 optionalDependencies: @@ -11989,7 +11895,7 @@ snapshots: '@cloudflare/workerd-linux-arm64': 1.20251217.0 '@cloudflare/workerd-windows-64': 1.20251217.0 - wrangler@4.56.0(@cloudflare/workers-types@4.20251219.0): + wrangler@4.56.0: dependencies: '@cloudflare/kv-asset-handler': 0.4.1 '@cloudflare/unenv-preset': 2.7.13(unenv@2.0.0-rc.24)(workerd@1.20251217.0) @@ -12000,7 +11906,6 @@ snapshots: unenv: 2.0.0-rc.24 workerd: 1.20251217.0 optionalDependencies: - '@cloudflare/workers-types': 4.20251219.0 fsevents: 2.3.3 transitivePeerDependencies: - bufferutil diff --git a/tests/app/fastify-entry.ts b/tests/app/fastify-entry.ts index 6167f9cf..e281a679 100644 --- a/tests/app/fastify-entry.ts +++ b/tests/app/fastify-entry.ts @@ -1,6 +1,7 @@ import awesomeEntry from "virtual:ud:catch-all?default"; import type { ServeReturn } from "@photonjs/core/serve"; -import { apply, serve } from "@photonjs/fastify"; +import { serve } from "@photonjs/fastify"; +import { apply } from "@universal-middleware/fastify"; import awesomeMiddlewares from "awesome-framework/middlewares"; import fastify, { type FastifyInstance } from "fastify"; @@ -10,12 +11,12 @@ async function startServer(): Promise> { forceCloseConnections: true, }); - await apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); - app.get("/serverid", (_, reply) => { reply.send("fastify"); }); + await apply(app, [...awesomeMiddlewares, awesomeEntry.fetch]); + return serve(app); } diff --git a/tests/app/package.json b/tests/app/package.json index 14e51a3a..9b8c3bd2 100644 --- a/tests/app/package.json +++ b/tests/app/package.json @@ -25,12 +25,13 @@ "@universal-middleware/core": "^0.4.14", "pkg-types": "^2.3.0", "typescript": "^5.9.3", - "vite": "^7.2.4", + "vite": "^7.3.1", "wrangler": "^4.56.0" }, "dependencies": { "@hattip/router": "^0.0.49", "@universal-middleware/express": "^0.4.23", + "@universal-middleware/fastify": "^0.5.23", "@universal-middleware/hattip": "^0.4.15", "@universal-middleware/hono": "^0.4.20", "awesome-framework": "workspace:", From c303bedcad4c6c908f76f3dd13bafa3ae321de9e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 16:35:45 +0100 Subject: [PATCH 09/62] chore --- packages/runtime/src/vite.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index 20a190da..de9f7d46 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -50,10 +50,11 @@ export function serve(): Plugin[] { }, load: { filter: { - id: [/^\0.*[?&]enhanced\b/], + // biome-ignore lint/suspicious/noControlCharactersInRegex: ok + id: [/^\x00.*[?&]enhanced\b/], }, // TODO create an util in UM to compile enhance - async handler(id) { + handler(id) { const wrappedModule = id.slice(1).replace(re_enhanced, ""); if (!wrappedModule.match(re_catchAll)) { From 1f0604c3b7f42d3ee0fc57b43e79c3485fa58e74 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 17:16:43 +0100 Subject: [PATCH 10/62] chore: use UM helper --- example/app-cloudflare/package.json | 2 +- example/app-hono/package.json | 2 +- example/app-netlify/package.json | 2 +- example/app-vercel/package.json | 2 +- example/awesome-framework/package.json | 2 +- packages/core/package.json | 2 +- packages/elysia/package.json | 2 +- packages/express/package.json | 2 +- packages/fastify/package.json | 2 +- packages/h3/package.json | 2 +- packages/hattip/package.json | 2 +- packages/hono/package.json | 2 +- packages/runtime/package.json | 2 +- packages/runtime/src/vite.ts | 9 +- packages/srvx/package.json | 2 +- pnpm-lock.yaml | 135 ++++++++++++------------- tests/app/package.json | 2 +- 17 files changed, 89 insertions(+), 85 deletions(-) diff --git a/example/app-cloudflare/package.json b/example/app-cloudflare/package.json index 2632aace..8d6da102 100644 --- a/example/app-cloudflare/package.json +++ b/example/app-cloudflare/package.json @@ -20,7 +20,7 @@ "wrangler": "^4.56.0" }, "dependencies": { - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "awesome-framework": "0.0.0", "hono": "^4.11.1" } diff --git a/example/app-hono/package.json b/example/app-hono/package.json index 8fe28c20..9aaa5061 100644 --- a/example/app-hono/package.json +++ b/example/app-hono/package.json @@ -21,7 +21,7 @@ "vite": "^7.3.1" }, "dependencies": { - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "awesome-framework": "0.0.0", "hono": "^4.11.1" } diff --git a/example/app-netlify/package.json b/example/app-netlify/package.json index fb056976..52c25901 100644 --- a/example/app-netlify/package.json +++ b/example/app-netlify/package.json @@ -19,7 +19,7 @@ "vite": "^7.3.1" }, "dependencies": { - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "awesome-framework": "0.0.0" } } diff --git a/example/app-vercel/package.json b/example/app-vercel/package.json index a740c418..5021d8f4 100644 --- a/example/app-vercel/package.json +++ b/example/app-vercel/package.json @@ -19,7 +19,7 @@ "wrangler": "^4.56.0" }, "dependencies": { - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "awesome-framework": "0.0.0" } } diff --git a/example/awesome-framework/package.json b/example/awesome-framework/package.json index 519fe72b..6051b781 100644 --- a/example/awesome-framework/package.json +++ b/example/awesome-framework/package.json @@ -9,7 +9,7 @@ "dependencies": { "@photonjs/core": "^0.1.21", "@photonjs/runtime": "^0.1.16", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "@universal-middleware/sirv": "^0.1.24" }, "devDependencies": { diff --git a/packages/core/package.json b/packages/core/package.json index b708d75b..e80e79f9 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -26,7 +26,7 @@ "@brillout/vite-plugin-server-entry": "^0.7.15", "@universal-middleware/cloudflare": "^0.4.10", "@universal-middleware/compress": "^0.2.34", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "@universal-middleware/express": "^0.4.22", "@universal-middleware/sirv": "^0.1.24", "estree-walker": "^3.0.3", diff --git a/packages/elysia/package.json b/packages/elysia/package.json index 354ba059..50777915 100644 --- a/packages/elysia/package.json +++ b/packages/elysia/package.json @@ -50,7 +50,7 @@ "@types/bun": "^1.3.3", "@types/deno": "^2.5.0", "@types/node": "^22.19.1", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "elysia": "^1.4.19", "tsdown": "^0.18.1", "typescript": "^5.9.3", diff --git a/packages/express/package.json b/packages/express/package.json index 233c8e9a..1247ff9d 100644 --- a/packages/express/package.json +++ b/packages/express/package.json @@ -36,7 +36,7 @@ }, "devDependencies": { "@types/node": "^22.19.1", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "express": "^5.2.1", "srvx": "^0.9.8", "tsdown": "^0.18.1", diff --git a/packages/fastify/package.json b/packages/fastify/package.json index bd97c681..43517ddc 100644 --- a/packages/fastify/package.json +++ b/packages/fastify/package.json @@ -36,7 +36,7 @@ }, "devDependencies": { "@types/node": "^22.19.1", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "ansis": "^4.2.0", "fastify": "^5.6.2", "srvx": "^0.9.8", diff --git a/packages/h3/package.json b/packages/h3/package.json index 1a0da744..9c687cfc 100644 --- a/packages/h3/package.json +++ b/packages/h3/package.json @@ -49,7 +49,7 @@ "@types/bun": "^1.3.3", "@types/deno": "^2.5.0", "@types/node": "^22.19.1", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "h3": "^1.15.4", "tsdown": "^0.18.1", "typescript": "^5.9.3", diff --git a/packages/hattip/package.json b/packages/hattip/package.json index 048b4094..22a8ed5b 100644 --- a/packages/hattip/package.json +++ b/packages/hattip/package.json @@ -29,7 +29,7 @@ "@types/bun": "^1.3.3", "@types/deno": "^2.5.0", "@types/node": "^22.19.1", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "tsdown": "^0.18.1", "typescript": "^5.9.3", "vite": "^7.3.1" diff --git a/packages/hono/package.json b/packages/hono/package.json index a1cbcda9..60f0b4f8 100644 --- a/packages/hono/package.json +++ b/packages/hono/package.json @@ -38,7 +38,7 @@ "@types/bun": "^1.3.3", "@types/deno": "^2.5.0", "@types/node": "^22.19.1", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "tsdown": "^0.18.1", "typescript": "^5.9.3", "vite": "^7.3.1" diff --git a/packages/runtime/package.json b/packages/runtime/package.json index 0cf33212..3def3274 100644 --- a/packages/runtime/package.json +++ b/packages/runtime/package.json @@ -24,7 +24,7 @@ "@photonjs/srvx": "workspace:^", "@universal-deploy/node": "^0.0.1", "@universal-deploy/store": "^0.0.5", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "@universal-middleware/sirv": "^0.1.24", "srvx": "^0.9.8", "standaloner": "^0.1.11" diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index de9f7d46..37ede48d 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -1,3 +1,4 @@ +import { compileEnhance } from "@universal-middleware/core"; import type { Plugin } from "vite"; const re_enhanced = /[?&]enhanced\b/; @@ -62,9 +63,13 @@ export function serve(): Plugin[] { return; } + const compiledEnhance = compileEnhance("mod.fetch", { + path: "/**", + method: "GET", + }); + return `import mod from ${JSON.stringify(wrappedModule)}; -mod.fetch[Symbol.for("unPath")] = ${JSON.stringify("/**")}; -mod.fetch[Symbol.for("unMethod")] = ${JSON.stringify("GET")}; +${compiledEnhance} export default mod; `; }, diff --git a/packages/srvx/package.json b/packages/srvx/package.json index 1078c8f6..a012d356 100644 --- a/packages/srvx/package.json +++ b/packages/srvx/package.json @@ -49,7 +49,7 @@ "@types/bun": "^1.3.3", "@types/deno": "^2.5.0", "@types/node": "^22.19.1", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "srvx": "^0.9.8", "tsdown": "^0.18.1", "typescript": "^5.9.3", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 54ed333c..2ad3243e 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -63,8 +63,8 @@ importers: example/app-cloudflare: dependencies: '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -100,8 +100,8 @@ importers: example/app-hono: dependencies: '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -134,8 +134,8 @@ importers: example/app-netlify: dependencies: '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -162,8 +162,8 @@ importers: example/app-vercel: dependencies: '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) awesome-framework: specifier: 0.0.0 version: link:../awesome-framework @@ -176,7 +176,7 @@ importers: version: link:../../packages/runtime '@photonjs/vercel': specifier: ^0.1.22 - version: 0.1.22(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(rollup@4.53.5)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 0.1.22(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(h3@1.15.4)(rollup@4.53.5)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) e2e: specifier: 'workspace:' version: link:../../tests/e2e @@ -202,8 +202,8 @@ importers: specifier: ^0.1.16 version: link:../../packages/runtime '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': specifier: ^0.1.24 version: 0.1.24 @@ -225,7 +225,7 @@ importers: dependencies: '@photonjs/cloudflare': specifier: ^0.1.13 - version: 0.1.13(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0) + version: 0.1.13(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0) '@photonjs/runtime': specifier: ^0.1.16 version: link:../../packages/runtime @@ -310,13 +310,13 @@ importers: version: 0.7.15 '@universal-middleware/cloudflare': specifier: ^0.4.10 - version: 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + version: 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8) '@universal-middleware/compress': specifier: ^0.2.34 version: 0.2.34 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/express': specifier: ^0.4.22 version: 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) @@ -371,7 +371,7 @@ importers: version: link:../core '@universal-middleware/elysia': specifier: ^0.6.2 - version: 0.6.2(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + version: 0.6.2(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(h3@1.15.4)(srvx@0.9.8) devDependencies: '@elysiajs/node': specifier: ^1.4.2 @@ -386,8 +386,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) elysia: specifier: ^1.4.19 version: 1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3) @@ -414,8 +414,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) express: specifier: ^5.2.1 version: 5.2.1 @@ -445,8 +445,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) ansis: specifier: ^4.2.0 version: 4.2.0 @@ -473,7 +473,7 @@ importers: version: link:../core '@universal-middleware/h3': specifier: ^0.4.15 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8) devDependencies: '@types/bun': specifier: ^1.3.3 @@ -485,8 +485,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) h3: specifier: ^1.15.4 version: 1.15.4 @@ -519,8 +519,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) tsdown: specifier: ^0.18.1 version: 0.18.1(typescript@5.9.3) @@ -550,8 +550,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) tsdown: specifier: ^0.18.1 version: 0.18.1(typescript@5.9.3) @@ -569,13 +569,13 @@ importers: version: link:../srvx '@universal-deploy/node': specifier: ^0.0.1 - version: 0.0.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + version: 0.0.1(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) '@universal-deploy/store': specifier: ^0.0.5 version: 0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': specifier: ^0.1.24 version: 0.1.24 @@ -606,7 +606,7 @@ importers: version: link:../core '@universal-middleware/srvx': specifier: ^0.1.1 - version: 0.1.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + version: 0.1.1(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8) devDependencies: '@types/bun': specifier: ^1.3.3 @@ -618,8 +618,8 @@ importers: specifier: ^22.19.1 version: 22.19.1 '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) srvx: specifier: ^0.9.8 version: 0.9.8 @@ -709,8 +709,8 @@ importers: specifier: ^0.0.5 version: 0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/core': - specifier: ^0.4.14 - version: 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + specifier: ^0.4.16 + version: 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) pkg-types: specifier: ^2.3.0 version: 2.3.0 @@ -3013,15 +3013,15 @@ packages: '@universal-middleware/compress@0.2.34': resolution: {integrity: sha512-zpLaiHHEfx1ouahZ+NKc5UScsiRAsEn+wiwWMH55JAEeUQ73zymw3e1kZg45Tr/oQh8X3PL0YrRKXDdc5Lt8WA==} - '@universal-middleware/core@0.4.15': - resolution: {integrity: sha512-4nUc79ANoExxldCGz4b2ttyxjopcmO8MH7sbJLCvFKxa9DdbHfsXI9+HAvgbKAYqC8FAFbadsMzqnAeSqis1dw==} + '@universal-middleware/core@0.4.16': + resolution: {integrity: sha512-8gZmgQDdX5GoQE49eAUMXEtCRbfzTLCibbc26HlG65PS3QeTDJp+hw3kNMA+4KWEhWaOcrSjsmNHFEpeE77JIQ==} peerDependencies: - '@cloudflare/workers-types': ^4.20260114.0 + '@cloudflare/workers-types': ^4.20260118.0 '@hattip/core': ^0.0.49 '@types/express': ^4 || ^5 '@webroute/route': ^0.8.0 elysia: ^1.4.22 - fastify: ^5.6.2 + fastify: ^5.7.1 h3: ^1.15.4 hono: ^4.11.4 srvx: ^0.8 || ^0.9 @@ -7248,11 +7248,11 @@ snapshots: '@oxc-project/types@0.98.0': {} - '@photonjs/cloudflare@0.1.13(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0)': + '@photonjs/cloudflare@0.1.13(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0)': dependencies: '@cloudflare/vite-plugin': 1.19.0(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))(workerd@1.20251217.0)(wrangler@4.56.0) - '@photonjs/core': 0.1.21(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) - '@universal-middleware/cloudflare': 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + '@photonjs/core': 0.1.21(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2)) + '@universal-middleware/cloudflare': 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -7269,12 +7269,12 @@ snapshots: - workerd - wrangler - '@photonjs/core@0.1.21(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@photonjs/core@0.1.21(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@brillout/vite-plugin-server-entry': 0.7.15 - '@universal-middleware/cloudflare': 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + '@universal-middleware/cloudflare': 0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8) '@universal-middleware/compress': 0.2.34 - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/express': 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': 0.1.24 estree-walker: 3.0.3 @@ -7293,14 +7293,14 @@ snapshots: - hono - srvx - '@photonjs/vercel@0.1.22(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(rollup@4.53.5)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@photonjs/vercel@0.1.22(@hattip/core@0.0.49)(@photonjs/core@packages+core)(@photonjs/runtime@packages+runtime)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(h3@1.15.4)(rollup@4.53.5)(srvx@0.9.8)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@brillout/libassert': 0.5.8 '@manypkg/find-root': 3.1.0 '@photonjs/core': link:packages/core '@photonjs/runtime': link:packages/runtime - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) - '@universal-middleware/vercel': 0.4.29(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/vercel': 0.4.29(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(h3@1.15.4)(srvx@0.9.8) '@vercel/build-utils': 13.2.4 '@vercel/nft': 1.1.1(rollup@4.53.5) '@vercel/routing-utils': 5.3.1 @@ -8194,7 +8194,7 @@ snapshots: '@ungap/structured-clone@1.3.0': {} - '@universal-deploy/node@0.0.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': + '@universal-deploy/node@0.0.1(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(vite@7.3.1(@types/node@22.19.1)(jiti@2.6.1)(lightningcss@1.30.2)(tsx@4.20.6)(yaml@2.8.2))': dependencies: '@universal-deploy/store': 0.0.5(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/sirv': 0.1.24 @@ -8226,9 +8226,9 @@ snapshots: - hono - srvx - '@universal-middleware/cloudflare@0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': + '@universal-middleware/cloudflare@0.4.10(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8242,7 +8242,7 @@ snapshots: '@universal-middleware/compress@0.2.34': {} - '@universal-middleware/core@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': + '@universal-middleware/core@0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: regexparam: 3.0.0 tough-cookie: 6.0.0 @@ -8255,9 +8255,9 @@ snapshots: hono: 4.11.1 srvx: 0.9.8 - '@universal-middleware/elysia@0.6.2(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': + '@universal-middleware/elysia@0.6.2(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8271,7 +8271,7 @@ snapshots: '@universal-middleware/express@0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8285,7 +8285,7 @@ snapshots: '@universal-middleware/fastify@0.5.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/express': 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) fastify-raw-body: 5.0.0 transitivePeerDependencies: @@ -8299,9 +8299,9 @@ snapshots: - hono - srvx - '@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': + '@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8315,7 +8315,7 @@ snapshots: '@universal-middleware/hattip@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8329,7 +8329,7 @@ snapshots: '@universal-middleware/hono@0.4.20(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8346,9 +8346,9 @@ snapshots: mrmime: 2.0.1 totalist: 3.0.1 - '@universal-middleware/srvx@0.1.1(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': + '@universal-middleware/srvx@0.1.1(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) transitivePeerDependencies: - '@cloudflare/workers-types' - '@hattip/core' @@ -8360,15 +8360,14 @@ snapshots: - hono - srvx - '@universal-middleware/vercel@0.4.29(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8)': + '@universal-middleware/vercel@0.4.29(@hattip/core@0.0.49)(@types/express@5.0.6)(@universal-middleware/h3@0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8))(express@5.2.1)(h3@1.15.4)(srvx@0.9.8)': dependencies: - '@universal-middleware/core': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) + '@universal-middleware/core': 0.4.16(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) '@universal-middleware/express': 0.4.23(@hattip/core@0.0.49)(@types/express@5.0.6)(elysia@1.4.19(@sinclair/typebox@0.34.41)(@types/bun@1.3.3)(exact-mirror@0.2.2(@sinclair/typebox@0.34.41))(file-type@21.0.0)(openapi-types@12.1.3)(typescript@5.9.3))(fastify@5.6.2)(h3@1.15.4)(hono@4.11.1)(srvx@0.9.8) optionalDependencies: '@hattip/core': 0.0.49 - '@universal-middleware/h3': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(fastify@5.6.2)(h3@1.15.4)(srvx@0.9.8) + '@universal-middleware/h3': 0.4.15(@hattip/core@0.0.49)(@types/express@5.0.6)(h3@1.15.4)(srvx@0.9.8) express: 5.2.1 - fastify: 5.6.2 h3: 1.15.4 srvx: 0.9.8 transitivePeerDependencies: diff --git a/tests/app/package.json b/tests/app/package.json index 9b8c3bd2..93ec4505 100644 --- a/tests/app/package.json +++ b/tests/app/package.json @@ -22,7 +22,7 @@ "@types/express": "^5.0.6", "@types/node": "^22.19.1", "@universal-deploy/store": "^0.0.5", - "@universal-middleware/core": "^0.4.14", + "@universal-middleware/core": "^0.4.16", "pkg-types": "^2.3.0", "typescript": "^5.9.3", "vite": "^7.3.1", From b8158e028875a392189c468066dfaf67e6ba2bdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 17:29:34 +0100 Subject: [PATCH 11/62] chore --- packages/runtime/src/vite.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index 37ede48d..61c330ca 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -36,7 +36,7 @@ export function serve(): Plugin[] { resolveId: { filter: { - id: [re_enhanced, /^virtual:ud:catch-all\?default$/], + id: [re_enhanced, re_catchAll], }, async handler(id, importer) { if (importer?.match(re_enhanced)) return; @@ -54,7 +54,6 @@ export function serve(): Plugin[] { // biome-ignore lint/suspicious/noControlCharactersInRegex: ok id: [/^\x00.*[?&]enhanced\b/], }, - // TODO create an util in UM to compile enhance handler(id) { const wrappedModule = id.slice(1).replace(re_enhanced, ""); From 76fb654d449e9331fa4cef020671627e5d453d0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 17:45:16 +0100 Subject: [PATCH 12/62] chore --- packages/runtime/src/vite.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index 61c330ca..66086737 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -67,7 +67,9 @@ export function serve(): Plugin[] { method: "GET", }); - return `import mod from ${JSON.stringify(wrappedModule)}; + return ` +export * from ${JSON.stringify(wrappedModule)}; +import mod from ${JSON.stringify(wrappedModule)}; ${compiledEnhance} export default mod; `; From ec8226e4f2ab34626e883393e60a9c055a05cd28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 17:46:39 +0100 Subject: [PATCH 13/62] cleanup --- packages/runtime/src/vite.ts | 34 ---------------------------------- 1 file changed, 34 deletions(-) diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index 66086737..4d00b090 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -76,39 +76,5 @@ export default mod; }, }, }, - { - name: "photon:serve:transform-dev", - apply: "serve", - - applyToEnvironment(env) { - return env.config.consumer === "server"; - }, - - config(userConfig) { - userPort = userConfig.server?.port; - userHost = userConfig.server?.host; - }, - - transform: { - filter: { - code: [/process\.env\.PORT/, /process\.env\.PHOTON_HOSTNAME/], - }, - handler(code) { - let newCode = code; - let replaced = false; - if (userPort) { - newCode = newCode.replaceAll("process.env.PORT", JSON.stringify(String(userPort))); - replaced = true; - } - if (typeof userHost === "string") { - newCode = newCode.replaceAll("process.env.PHOTON_HOSTNAME", JSON.stringify(String(userHost))); - replaced = true; - } - if (replaced) { - return newCode; - } - }, - }, - }, ]; } From 2c47a2ce04d448770fc875ef7e5b193aa5047c0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 17:46:46 +0100 Subject: [PATCH 14/62] cleanup --- packages/runtime/src/vite.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index 4d00b090..03c3151b 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -6,8 +6,6 @@ const re_catchAll = /^virtual:ud:catch-all\?default$/; // Creates a server and listens for connections in Node/Deno/Bun export function serve(): Plugin[] { - let userPort: number | undefined; - let userHost: string | boolean | undefined; return [ { name: "photon:node:node-entry", From e98afae3783b5e31cb20e571c2a4dab303299fec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Thu, 22 Jan 2026 18:01:06 +0100 Subject: [PATCH 15/62] chore: broader http methods support by default --- packages/runtime/src/vite.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/runtime/src/vite.ts b/packages/runtime/src/vite.ts index 03c3151b..0b0044d2 100644 --- a/packages/runtime/src/vite.ts +++ b/packages/runtime/src/vite.ts @@ -62,7 +62,7 @@ export function serve(): Plugin[] { const compiledEnhance = compileEnhance("mod.fetch", { path: "/**", - method: "GET", + method: ["GET", "HEAD", "POST", "PUT", "DELETE", "OPTIONS", "PATCH"], }); return ` From 61cef6d9741571044afabd06a6e18551ead9c558 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=ABl=20Charles?= Date: Fri, 23 Jan 2026 11:22:12 +0100 Subject: [PATCH 16/62] wip --- packages/core/global.d.ts | 3 - packages/core/lib.deno.d.ts | 22003 ---------------- packages/core/package.json | 32 +- packages/core/src/api/internal.ts | 21 - packages/core/src/dev.ts | 1 - packages/core/src/index.ts | 95 +- packages/core/src/plugin/index.ts | 9 - packages/core/src/plugin/plugins/devServer.ts | 278 - packages/core/src/plugin/utils/dedupe.ts | 28 - packages/core/src/plugin/utils/resolve.ts | 21 - packages/core/src/plugin/utils/rollupTypes.ts | 12 - packages/core/src/serve.ts | 78 - packages/core/src/types.ts | 31 - packages/core/tsdown.config.ts | 14 +- packages/core/virtual.d.ts | 10 - packages/express/package.json | 2 +- packages/express/src/serve.node.ts | 2 +- packages/express/src/serve.ts | 2 +- packages/fastify/package.json | 2 +- packages/fastify/src/serve.node.ts | 2 +- packages/fastify/src/serve.ts | 2 +- packages/hattip/package.json | 2 +- packages/hattip/src/serve.ts | 2 +- packages/hattip/src/utils.ts | 20 +- packages/hono/package.json | 1 + packages/hono/src/serve-edge.ts | 2 +- packages/hono/src/serve.ts | 2 +- packages/hono/src/types.ts | 2 +- packages/runtime/package.json | 1 + packages/runtime/src/serve-utils.ts | 190 +- pnpm-lock.yaml | 70 +- 31 files changed, 146 insertions(+), 22794 deletions(-) delete mode 100644 packages/core/global.d.ts delete mode 100644 packages/core/lib.deno.d.ts delete mode 100644 packages/core/src/api/internal.ts delete mode 100644 packages/core/src/dev.ts delete mode 100644 packages/core/src/plugin/index.ts delete mode 100644 packages/core/src/plugin/plugins/devServer.ts delete mode 100644 packages/core/src/plugin/utils/dedupe.ts delete mode 100644 packages/core/src/plugin/utils/resolve.ts delete mode 100644 packages/core/src/plugin/utils/rollupTypes.ts delete mode 100644 packages/core/src/serve.ts delete mode 100644 packages/core/src/types.ts delete mode 100644 packages/core/virtual.d.ts diff --git a/packages/core/global.d.ts b/packages/core/global.d.ts deleted file mode 100644 index 1aaf1c9f..00000000 --- a/packages/core/global.d.ts +++ /dev/null @@ -1,3 +0,0 @@ -declare module "virtual:*" { - export default any; -} diff --git a/packages/core/lib.deno.d.ts b/packages/core/lib.deno.d.ts deleted file mode 100644 index 772e0f3e..00000000 --- a/packages/core/lib.deno.d.ts +++ /dev/null @@ -1,22003 +0,0 @@ -// Copyright 2018-2025 the Deno authors. MIT license. - -/// -/// -/// - -/** Deno provides extra properties on `import.meta`. These are included here - * to ensure that these are still available when using the Deno namespace in - * conjunction with other type libs, like `dom`. - * - * @category Platform - */ -interface ImportMeta { - /** A string representation of the fully qualified module URL. When the - * module is loaded locally, the value will be a file URL (e.g. - * `file:///path/module.ts`). - * - * You can also parse the string as a URL to determine more information about - * how the current module was loaded. For example to determine if a module was - * local or not: - * - * ```ts - * const url = new URL(import.meta.url); - * if (url.protocol === "file:") { - * console.log("this module was loaded locally"); - * } - * ``` - */ - url: string; - - /** The absolute path of the current module. - * - * This property is only provided for local modules (ie. using `file://` URLs). - * - * Example: - * ``` - * // Unix - * console.log(import.meta.filename); // /home/alice/my_module.ts - * - * // Windows - * console.log(import.meta.filename); // C:\alice\my_module.ts - * ``` - */ - filename?: string; - - /** The absolute path of the directory containing the current module. - * - * This property is only provided for local modules (ie. using `file://` URLs). - * - * * Example: - * ``` - * // Unix - * console.log(import.meta.dirname); // /home/alice - * - * // Windows - * console.log(import.meta.dirname); // C:\alice - * ``` - */ - dirname?: string; - - /** A flag that indicates if the current module is the main module that was - * called when starting the program under Deno. - * - * ```ts - * if (import.meta.main) { - * // this was loaded as the main module, maybe do some bootstrapping - * } - * ``` - */ - main: boolean; - - /** A function that returns resolved specifier as if it would be imported - * using `import(specifier)`. - * - * ```ts - * console.log(import.meta.resolve("./foo.js")); - * // file:///dev/foo.js - * ``` - */ - resolve(specifier: string): string; -} - -/** Deno supports [User Timing Level 3](https://w3c.github.io/user-timing) - * which is not widely supported yet in other runtimes. - * - * Check out the - * [Performance API](https://developer.mozilla.org/en-US/docs/Web/API/Performance) - * documentation on MDN for further information about how to use the API. - * - * @category Performance - */ -interface Performance { - /** Stores a timestamp with the associated name (a "mark"). */ - mark(markName: string, options?: PerformanceMarkOptions): PerformanceMark; - - /** Stores the `DOMHighResTimeStamp` duration between two marks along with the - * associated name (a "measure"). */ - measure( - measureName: string, - options?: PerformanceMeasureOptions, - ): PerformanceMeasure; -} - -/** - * Options which are used in conjunction with `performance.mark`. Check out the - * MDN - * [`performance.mark()`](https://developer.mozilla.org/en-US/docs/Web/API/Performance/mark#markoptions) - * documentation for more details. - * - * @category Performance - */ -interface PerformanceMarkOptions { - /** Metadata to be included in the mark. */ - // deno-lint-ignore no-explicit-any - detail?: any; - - /** Timestamp to be used as the mark time. */ - startTime?: number; -} - -/** - * Options which are used in conjunction with `performance.measure`. Check out the - * MDN - * [`performance.mark()`](https://developer.mozilla.org/en-US/docs/Web/API/Performance/measure#measureoptions) - * documentation for more details. - * - * @category Performance - */ -interface PerformanceMeasureOptions { - /** Metadata to be included in the measure. */ - // deno-lint-ignore no-explicit-any - detail?: any; - - /** Timestamp to be used as the start time or string to be used as start - * mark. */ - start?: string | number; - - /** Duration between the start and end times. */ - duration?: number; - - /** Timestamp to be used as the end time or string to be used as end mark. */ - end?: string | number; -} - -/** The global namespace where Deno specific, non-standard APIs are located. */ -declare namespace Deno { - /** A set of error constructors that are raised by Deno APIs. - * - * Can be used to provide more specific handling of failures within code - * which is using Deno APIs. For example, handling attempting to open a file - * which does not exist: - * - * ```ts - * try { - * const file = await Deno.open("./some/file.txt"); - * } catch (error) { - * if (error instanceof Deno.errors.NotFound) { - * console.error("the file was not found"); - * } else { - * // otherwise re-throw - * throw error; - * } - * } - * ``` - * - * @category Errors - */ - export namespace errors { - /** - * Raised when the underlying operating system indicates that the file - * was not found. - * - * @category Errors */ - export class NotFound extends Error {} - /** - * Raised when the underlying operating system indicates the current user - * which the Deno process is running under does not have the appropriate - * permissions to a file or resource. - * - * Before Deno 2.0, this error was raised when the user _did not_ provide - * required `--allow-*` flag. As of Deno 2.0, that case is now handled by - * the {@link NotCapable} error. - * - * @category Errors */ - export class PermissionDenied extends Error {} - /** - * Raised when the underlying operating system reports that a connection to - * a resource is refused. - * - * @category Errors */ - export class ConnectionRefused extends Error {} - /** - * Raised when the underlying operating system reports that a connection has - * been reset. With network servers, it can be a _normal_ occurrence where a - * client will abort a connection instead of properly shutting it down. - * - * @category Errors */ - export class ConnectionReset extends Error {} - /** - * Raised when the underlying operating system reports an `ECONNABORTED` - * error. - * - * @category Errors */ - export class ConnectionAborted extends Error {} - /** - * Raised when the underlying operating system reports an `ENOTCONN` error. - * - * @category Errors */ - export class NotConnected extends Error {} - /** - * Raised when attempting to open a server listener on an address and port - * that already has a listener. - * - * @category Errors */ - export class AddrInUse extends Error {} - /** - * Raised when the underlying operating system reports an `EADDRNOTAVAIL` - * error. - * - * @category Errors */ - export class AddrNotAvailable extends Error {} - /** - * Raised when trying to write to a resource and a broken pipe error occurs. - * This can happen when trying to write directly to `stdout` or `stderr` - * and the operating system is unable to pipe the output for a reason - * external to the Deno runtime. - * - * @category Errors */ - export class BrokenPipe extends Error {} - /** - * Raised when trying to create a resource, like a file, that already - * exits. - * - * @category Errors */ - export class AlreadyExists extends Error {} - /** - * Raised when an operation returns data that is invalid for the - * operation being performed. - * - * @category Errors */ - export class InvalidData extends Error {} - /** - * Raised when the underlying operating system reports that an I/O operation - * has timed out (`ETIMEDOUT`). - * - * @category Errors */ - export class TimedOut extends Error {} - /** - * Raised when the underlying operating system reports an `EINTR` error. In - * many cases, this underlying IO error will be handled internally within - * Deno, or result in an {@link BadResource} error instead. - * - * @category Errors */ - export class Interrupted extends Error {} - /** - * Raised when the underlying operating system would need to block to - * complete but an asynchronous (non-blocking) API is used. - * - * @category Errors */ - export class WouldBlock extends Error {} - /** - * Raised when expecting to write to a IO buffer resulted in zero bytes - * being written. - * - * @category Errors */ - export class WriteZero extends Error {} - /** - * Raised when attempting to read bytes from a resource, but the EOF was - * unexpectedly encountered. - * - * @category Errors */ - export class UnexpectedEof extends Error {} - /** - * The underlying IO resource is invalid or closed, and so the operation - * could not be performed. - * - * @category Errors */ - export class BadResource extends Error {} - /** - * Raised in situations where when attempting to load a dynamic import, - * too many redirects were encountered. - * - * @category Errors */ - export class Http extends Error {} - /** - * Raised when the underlying IO resource is not available because it is - * being awaited on in another block of code. - * - * @category Errors */ - export class Busy extends Error {} - /** - * Raised when the underlying Deno API is asked to perform a function that - * is not currently supported. - * - * @category Errors */ - export class NotSupported extends Error {} - /** - * Raised when too many symbolic links were encountered when resolving the - * filename. - * - * @category Errors */ - export class FilesystemLoop extends Error {} - /** - * Raised when trying to open, create or write to a directory. - * - * @category Errors */ - export class IsADirectory extends Error {} - /** - * Raised when performing a socket operation but the remote host is - * not reachable. - * - * @category Errors */ - export class NetworkUnreachable extends Error {} - /** - * Raised when trying to perform an operation on a path that is not a - * directory, when directory is required. - * - * @category Errors */ - export class NotADirectory extends Error {} - - /** - * Raised when trying to perform an operation while the relevant Deno - * permission (like `--allow-read`) has not been granted. - * - * Before Deno 2.0, this condition was covered by the {@link PermissionDenied} - * error. - * - * @category Errors */ - export class NotCapable extends Error {} - - export {}; // only export exports - } - - /** The current process ID of this instance of the Deno CLI. - * - * ```ts - * console.log(Deno.pid); - * ``` - * - * @category Runtime - */ - export const pid: number; - - /** - * The process ID of parent process of this instance of the Deno CLI. - * - * ```ts - * console.log(Deno.ppid); - * ``` - * - * @category Runtime - */ - export const ppid: number; - - /** @category Runtime */ - export interface MemoryUsage { - /** The number of bytes of the current Deno's process resident set size, - * which is the amount of memory occupied in main memory (RAM). */ - rss: number; - /** The total size of the heap for V8, in bytes. */ - heapTotal: number; - /** The amount of the heap used for V8, in bytes. */ - heapUsed: number; - /** Memory, in bytes, associated with JavaScript objects outside of the - * JavaScript isolate. */ - external: number; - } - - /** - * Returns an object describing the memory usage of the Deno process and the - * V8 subsystem measured in bytes. - * - * @category Runtime - */ - export function memoryUsage(): MemoryUsage; - - /** - * Get the `hostname` of the machine the Deno process is running on. - * - * ```ts - * console.log(Deno.hostname()); - * ``` - * - * Requires `allow-sys` permission. - * - * @tags allow-sys - * @category Runtime - */ - export function hostname(): string; - - /** - * Returns an array containing the 1, 5, and 15 minute load averages. The - * load average is a measure of CPU and IO utilization of the last one, five, - * and 15 minute periods expressed as a fractional number. Zero means there - * is no load. On Windows, the three values are always the same and represent - * the current load, not the 1, 5 and 15 minute load averages. - * - * ```ts - * console.log(Deno.loadavg()); // e.g. [ 0.71, 0.44, 0.44 ] - * ``` - * - * Requires `allow-sys` permission. - * - * On Windows there is no API available to retrieve this information and this method returns `[ 0, 0, 0 ]`. - * - * @tags allow-sys - * @category Runtime - */ - export function loadavg(): number[]; - - /** - * The information for a network interface returned from a call to - * {@linkcode Deno.networkInterfaces}. - * - * @category Network - */ - export interface NetworkInterfaceInfo { - /** The network interface name. */ - name: string; - /** The IP protocol version. */ - family: "IPv4" | "IPv6"; - /** The IP address bound to the interface. */ - address: string; - /** The netmask applied to the interface. */ - netmask: string; - /** The IPv6 scope id or `null`. */ - scopeid: number | null; - /** The CIDR range. */ - cidr: string; - /** The MAC address. */ - mac: string; - } - - /** - * Returns an array of the network interface information. - * - * ```ts - * console.log(Deno.networkInterfaces()); - * ``` - * - * Requires `allow-sys` permission. - * - * @tags allow-sys - * @category Network - */ - export function networkInterfaces(): NetworkInterfaceInfo[]; - - /** - * Displays the total amount of free and used physical and swap memory in the - * system, as well as the buffers and caches used by the kernel. - * - * This is similar to the `free` command in Linux - * - * ```ts - * console.log(Deno.systemMemoryInfo()); - * ``` - * - * Requires `allow-sys` permission. - * - * @tags allow-sys - * @category Runtime - */ - export function systemMemoryInfo(): SystemMemoryInfo; - - /** - * Information returned from a call to {@linkcode Deno.systemMemoryInfo}. - * - * @category Runtime - */ - export interface SystemMemoryInfo { - /** Total installed memory in bytes. */ - total: number; - /** Unused memory in bytes. */ - free: number; - /** Estimation of how much memory, in bytes, is available for starting new - * applications, without swapping. Unlike the data provided by the cache or - * free fields, this field takes into account page cache and also that not - * all reclaimable memory will be reclaimed due to items being in use. - */ - available: number; - /** Memory used by kernel buffers. */ - buffers: number; - /** Memory used by the page cache and slabs. */ - cached: number; - /** Total swap memory. */ - swapTotal: number; - /** Unused swap memory. */ - swapFree: number; - } - - /** Reflects the `NO_COLOR` environment variable at program start. - * - * When the value is `true`, the Deno CLI will attempt to not send color codes - * to `stderr` or `stdout` and other command line programs should also attempt - * to respect this value. - * - * See: https://no-color.org/ - * - * @category Runtime - */ - export const noColor: boolean; - - /** - * Returns the release version of the Operating System. - * - * ```ts - * console.log(Deno.osRelease()); - * ``` - * - * Requires `allow-sys` permission. - * Under consideration to possibly move to Deno.build or Deno.versions and if - * it should depend sys-info, which may not be desirable. - * - * @tags allow-sys - * @category Runtime - */ - export function osRelease(): string; - - /** - * Returns the Operating System uptime in number of seconds. - * - * ```ts - * console.log(Deno.osUptime()); - * ``` - * - * Requires `allow-sys` permission. - * - * @tags allow-sys - * @category Runtime - */ - export function osUptime(): number; - - /** - * Options which define the permissions within a test or worker context. - * - * `"inherit"` ensures that all permissions of the parent process will be - * applied to the test context. `"none"` ensures the test context has no - * permissions. A `PermissionOptionsObject` provides a more specific - * set of permissions to the test context. - * - * @category Permissions */ - export type PermissionOptions = "inherit" | "none" | PermissionOptionsObject; - - /** - * A set of options which can define the permissions within a test or worker - * context at a highly specific level. - * - * @category Permissions */ - export interface PermissionOptionsObject { - /** Specifies if the `env` permission should be requested or revoked. - * If set to `"inherit"`, the current `env` permission will be inherited. - * If set to `true`, the global `env` permission will be requested. - * If set to `false`, the global `env` permission will be revoked. - * - * @default {false} - */ - env?: "inherit" | boolean | string[]; - - /** Specifies if the `ffi` permission should be requested or revoked. - * If set to `"inherit"`, the current `ffi` permission will be inherited. - * If set to `true`, the global `ffi` permission will be requested. - * If set to `false`, the global `ffi` permission will be revoked. - * - * @default {false} - */ - ffi?: "inherit" | boolean | Array; - - /** Specifies if the `import` permission should be requested or revoked. - * If set to `"inherit"` the current `import` permission will be inherited. - * If set to `true`, the global `import` permission will be requested. - * If set to `false`, the global `import` permission will be revoked. - * If set to `Array`, the `import` permissions will be requested with the - * specified domains. - */ - import?: "inherit" | boolean | Array; - - /** Specifies if the `net` permission should be requested or revoked. - * if set to `"inherit"`, the current `net` permission will be inherited. - * if set to `true`, the global `net` permission will be requested. - * if set to `false`, the global `net` permission will be revoked. - * if set to `string[]`, the `net` permission will be requested with the - * specified host strings with the format `"[:]`. - * - * @default {false} - * - * Examples: - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test({ - * name: "inherit", - * permissions: { - * net: "inherit", - * }, - * async fn() { - * const status = await Deno.permissions.query({ name: "net" }) - * assertEquals(status.state, "granted"); - * }, - * }); - * ``` - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test({ - * name: "true", - * permissions: { - * net: true, - * }, - * async fn() { - * const status = await Deno.permissions.query({ name: "net" }); - * assertEquals(status.state, "granted"); - * }, - * }); - * ``` - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test({ - * name: "false", - * permissions: { - * net: false, - * }, - * async fn() { - * const status = await Deno.permissions.query({ name: "net" }); - * assertEquals(status.state, "denied"); - * }, - * }); - * ``` - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test({ - * name: "localhost:8080", - * permissions: { - * net: ["localhost:8080"], - * }, - * async fn() { - * const status = await Deno.permissions.query({ name: "net", host: "localhost:8080" }); - * assertEquals(status.state, "granted"); - * }, - * }); - * ``` - */ - net?: "inherit" | boolean | string[]; - - /** Specifies if the `read` permission should be requested or revoked. - * If set to `"inherit"`, the current `read` permission will be inherited. - * If set to `true`, the global `read` permission will be requested. - * If set to `false`, the global `read` permission will be revoked. - * If set to `Array`, the `read` permission will be requested with the - * specified file paths. - * - * @default {false} - */ - read?: "inherit" | boolean | Array; - - /** Specifies if the `run` permission should be requested or revoked. - * If set to `"inherit"`, the current `run` permission will be inherited. - * If set to `true`, the global `run` permission will be requested. - * If set to `false`, the global `run` permission will be revoked. - * - * @default {false} - */ - run?: "inherit" | boolean | Array; - - /** Specifies if the `sys` permission should be requested or revoked. - * If set to `"inherit"`, the current `sys` permission will be inherited. - * If set to `true`, the global `sys` permission will be requested. - * If set to `false`, the global `sys` permission will be revoked. - * - * @default {false} - */ - sys?: "inherit" | boolean | string[]; - - /** Specifies if the `write` permission should be requested or revoked. - * If set to `"inherit"`, the current `write` permission will be inherited. - * If set to `true`, the global `write` permission will be requested. - * If set to `false`, the global `write` permission will be revoked. - * If set to `Array`, the `write` permission will be requested with the - * specified file paths. - * - * @default {false} - */ - write?: "inherit" | boolean | Array; - } - - /** - * Context that is passed to a testing function, which can be used to either - * gain information about the current test, or register additional test - * steps within the current test. - * - * @category Testing */ - export interface TestContext { - /** The current test name. */ - name: string; - /** The string URL of the current test. */ - origin: string; - /** If the current test is a step of another test, the parent test context - * will be set here. */ - parent?: TestContext; - - /** Run a sub step of the parent test or step. Returns a promise - * that resolves to a boolean signifying if the step completed successfully. - * - * The returned promise never rejects unless the arguments are invalid. - * - * If the test was ignored the promise returns `false`. - * - * ```ts - * Deno.test({ - * name: "a parent test", - * async fn(t) { - * console.log("before the step"); - * await t.step({ - * name: "step 1", - * fn(t) { - * console.log("current step:", t.name); - * } - * }); - * console.log("after the step"); - * } - * }); - * ``` - */ - step(definition: TestStepDefinition): Promise; - - /** Run a sub step of the parent test or step. Returns a promise - * that resolves to a boolean signifying if the step completed successfully. - * - * The returned promise never rejects unless the arguments are invalid. - * - * If the test was ignored the promise returns `false`. - * - * ```ts - * Deno.test( - * "a parent test", - * async (t) => { - * console.log("before the step"); - * await t.step( - * "step 1", - * (t) => { - * console.log("current step:", t.name); - * } - * ); - * console.log("after the step"); - * } - * ); - * ``` - */ - step( - name: string, - fn: (t: TestContext) => void | Promise, - ): Promise; - - /** Run a sub step of the parent test or step. Returns a promise - * that resolves to a boolean signifying if the step completed successfully. - * - * The returned promise never rejects unless the arguments are invalid. - * - * If the test was ignored the promise returns `false`. - * - * ```ts - * Deno.test(async function aParentTest(t) { - * console.log("before the step"); - * await t.step(function step1(t) { - * console.log("current step:", t.name); - * }); - * console.log("after the step"); - * }); - * ``` - */ - step(fn: (t: TestContext) => void | Promise): Promise; - } - - /** @category Testing */ - export interface TestStepDefinition { - /** The test function that will be tested when this step is executed. The - * function can take an argument which will provide information about the - * current step's context. */ - fn: (t: TestContext) => void | Promise; - /** The name of the step. */ - name: string; - /** If truthy the current test step will be ignored. - * - * This is a quick way to skip over a step, but also can be used for - * conditional logic, like determining if an environment feature is present. - */ - ignore?: boolean; - /** Check that the number of async completed operations after the test step - * is the same as number of dispatched operations. This ensures that the - * code tested does not start async operations which it then does - * not await. This helps in preventing logic errors and memory leaks - * in the application code. - * - * Defaults to the parent test or step's value. */ - sanitizeOps?: boolean; - /** Ensure the test step does not "leak" resources - like open files or - * network connections - by ensuring the open resources at the start of the - * step match the open resources at the end of the step. - * - * Defaults to the parent test or step's value. */ - sanitizeResources?: boolean; - /** Ensure the test step does not prematurely cause the process to exit, - * for example via a call to {@linkcode Deno.exit}. - * - * Defaults to the parent test or step's value. */ - sanitizeExit?: boolean; - } - - /** @category Testing */ - export interface TestDefinition { - fn: (t: TestContext) => void | Promise; - /** The name of the test. */ - name: string; - /** If truthy the current test step will be ignored. - * - * It is a quick way to skip over a step, but also can be used for - * conditional logic, like determining if an environment feature is present. - */ - ignore?: boolean; - /** If at least one test has `only` set to `true`, only run tests that have - * `only` set to `true` and fail the test suite. */ - only?: boolean; - /** Check that the number of async completed operations after the test step - * is the same as number of dispatched operations. This ensures that the - * code tested does not start async operations which it then does - * not await. This helps in preventing logic errors and memory leaks - * in the application code. - * - * @default {true} */ - sanitizeOps?: boolean; - /** Ensure the test step does not "leak" resources - like open files or - * network connections - by ensuring the open resources at the start of the - * test match the open resources at the end of the test. - * - * @default {true} */ - sanitizeResources?: boolean; - /** Ensure the test case does not prematurely cause the process to exit, - * for example via a call to {@linkcode Deno.exit}. - * - * @default {true} */ - sanitizeExit?: boolean; - /** Specifies the permissions that should be used to run the test. - * - * Set this to "inherit" to keep the calling runtime permissions, set this - * to "none" to revoke all permissions, or set a more specific set of - * permissions using a {@linkcode PermissionOptionsObject}. - * - * @default {"inherit"} */ - permissions?: PermissionOptions; - } - - /** Register a test which will be run when `deno test` is used on the command - * line and the containing module looks like a test module. - * - * `fn` can be async if required. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test({ - * name: "example test", - * fn() { - * assertEquals("world", "world"); - * }, - * }); - * - * Deno.test({ - * name: "example ignored test", - * ignore: Deno.build.os === "windows", - * fn() { - * // This test is ignored only on Windows machines - * }, - * }); - * - * Deno.test({ - * name: "example async test", - * async fn() { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * } - * }); - * ``` - * - * @category Testing - */ - export const test: DenoTest; - - /** - * @category Testing - */ - export interface DenoTest { - /** Register a test which will be run when `deno test` is used on the command - * line and the containing module looks like a test module. - * - * `fn` can be async if required. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test({ - * name: "example test", - * fn() { - * assertEquals("world", "world"); - * }, - * }); - * - * Deno.test({ - * name: "example ignored test", - * ignore: Deno.build.os === "windows", - * fn() { - * // This test is ignored only on Windows machines - * }, - * }); - * - * Deno.test({ - * name: "example async test", - * async fn() { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * } - * }); - * ``` - * - * @category Testing - */ - (t: TestDefinition): void; - - /** Register a test which will be run when `deno test` is used on the command - * line and the containing module looks like a test module. - * - * `fn` can be async if required. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test("My test description", () => { - * assertEquals("hello", "hello"); - * }); - * - * Deno.test("My async test description", async () => { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * }); - * ``` - * - * @category Testing - */ - (name: string, fn: (t: TestContext) => void | Promise): void; - - /** Register a test which will be run when `deno test` is used on the command - * line and the containing module looks like a test module. - * - * `fn` can be async if required. Declared function must have a name. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test(function myTestName() { - * assertEquals("hello", "hello"); - * }); - * - * Deno.test(async function myOtherTestName() { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * }); - * ``` - * - * @category Testing - */ - (fn: (t: TestContext) => void | Promise): void; - - /** Register a test which will be run when `deno test` is used on the command - * line and the containing module looks like a test module. - * - * `fn` can be async if required. - * - * ```ts - * import { assert, fail, assertEquals } from "jsr:@std/assert"; - * - * Deno.test("My test description", { permissions: { read: true } }, (): void => { - * assertEquals("hello", "hello"); - * }); - * - * Deno.test("My async test description", { permissions: { read: false } }, async (): Promise => { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * }); - * ``` - * - * @category Testing - */ - ( - name: string, - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Register a test which will be run when `deno test` is used on the command - * line and the containing module looks like a test module. - * - * `fn` can be async if required. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test( - * { - * name: "My test description", - * permissions: { read: true }, - * }, - * () => { - * assertEquals("hello", "hello"); - * }, - * ); - * - * Deno.test( - * { - * name: "My async test description", - * permissions: { read: false }, - * }, - * async () => { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * }, - * ); - * ``` - * - * @category Testing - */ - ( - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Register a test which will be run when `deno test` is used on the command - * line and the containing module looks like a test module. - * - * `fn` can be async if required. Declared function must have a name. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.test( - * { permissions: { read: true } }, - * function myTestName() { - * assertEquals("hello", "hello"); - * }, - * ); - * - * Deno.test( - * { permissions: { read: false } }, - * async function myOtherTestName() { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * }, - * ); - * ``` - * - * @category Testing - */ - ( - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Shorthand property for ignoring a particular test case. - * - * @category Testing - */ - ignore(t: Omit): void; - - /** Shorthand property for ignoring a particular test case. - * - * @category Testing - */ - ignore(name: string, fn: (t: TestContext) => void | Promise): void; - - /** Shorthand property for ignoring a particular test case. - * - * @category Testing - */ - ignore(fn: (t: TestContext) => void | Promise): void; - - /** Shorthand property for ignoring a particular test case. - * - * @category Testing - */ - ignore( - name: string, - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Shorthand property for ignoring a particular test case. - * - * @category Testing - */ - ignore( - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Shorthand property for ignoring a particular test case. - * - * @category Testing - */ - ignore( - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Shorthand property for focusing a particular test case. - * - * @category Testing - */ - only(t: Omit): void; - - /** Shorthand property for focusing a particular test case. - * - * @category Testing - */ - only(name: string, fn: (t: TestContext) => void | Promise): void; - - /** Shorthand property for focusing a particular test case. - * - * @category Testing - */ - only(fn: (t: TestContext) => void | Promise): void; - - /** Shorthand property for focusing a particular test case. - * - * @category Testing - */ - only( - name: string, - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Shorthand property for focusing a particular test case. - * - * @category Testing - */ - only( - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Shorthand property for focusing a particular test case. - * - * @category Testing - */ - only( - options: Omit, - fn: (t: TestContext) => void | Promise, - ): void; - - /** Register a function to be called before all tests in the current scope. - * - * These functions are run in FIFO order (first in, first out). - * - * If an exception is raised during execution of this hook, the remaining `beforeAll` hooks will not be run. - * - * ```ts - * Deno.test.beforeAll(() => { - * // Setup code that runs once before all tests - * console.log("Setting up test suite"); - * }); - * ``` - * - * @category Testing - */ - beforeAll( - fn: () => void | Promise, - ): void; - - /** Register a function to be called before each test in the current scope. - * - * These functions are run in FIFO order (first in, first out). - * - * If an exception is raised during execution of this hook, the remaining hooks will not be run and the currently running - * test case will be marked as failed. - * - * ```ts - * Deno.test.beforeEach(() => { - * // Setup code that runs before each test - * console.log("Setting up test"); - * }); - * ``` - * - * @category Testing - */ - beforeEach(fn: () => void | Promise): void; - - /** Register a function to be called after each test in the current scope. - * - * These functions are run in LIFO order (last in, first out). - * - * If an exception is raised during execution of this hook, the remaining hooks will not be run and the currently running - * test case will be marked as failed. - * - * ```ts - * Deno.test.afterEach(() => { - * // Cleanup code that runs after each test - * console.log("Cleaning up test"); - * }); - * ``` - * - * @category Testing - */ - afterEach(fn: () => void | Promise): void; - - /** Register a function to be called after all tests in the current scope have finished running. - * - * These functions are run in the LIFO order (last in, first out). - * - * If an exception is raised during execution of this hook, the remaining `afterAll` hooks will not be run. - * - * ```ts - * Deno.test.afterAll(() => { - * // Cleanup code that runs once after all tests - * console.log("Cleaning up test suite"); - * }); - * ``` - * - * @category Testing - */ - afterAll(fn: () => void | Promise): void; - } - - /** - * Context that is passed to a benchmarked function. The instance is shared - * between iterations of the benchmark. Its methods can be used for example - * to override of the measured portion of the function. - * - * @category Testing - */ - export interface BenchContext { - /** The current benchmark name. */ - name: string; - /** The string URL of the current benchmark. */ - origin: string; - - /** Restarts the timer for the bench measurement. This should be called - * after doing setup work which should not be measured. - * - * Warning: This method should not be used for benchmarks averaging less - * than 10μs per iteration. In such cases it will be disabled but the call - * will still have noticeable overhead, resulting in a warning. - * - * ```ts - * Deno.bench("foo", async (t) => { - * const data = await Deno.readFile("data.txt"); - * t.start(); - * // some operation on `data`... - * }); - * ``` - */ - start(): void; - - /** End the timer early for the bench measurement. This should be called - * before doing teardown work which should not be measured. - * - * Warning: This method should not be used for benchmarks averaging less - * than 10μs per iteration. In such cases it will be disabled but the call - * will still have noticeable overhead, resulting in a warning. - * - * ```ts - * Deno.bench("foo", async (t) => { - * using file = await Deno.open("data.txt"); - * t.start(); - * // some operation on `file`... - * t.end(); - * }); - * ``` - */ - end(): void; - } - - /** - * The interface for defining a benchmark test using {@linkcode Deno.bench}. - * - * @category Testing - */ - export interface BenchDefinition { - /** The test function which will be benchmarked. */ - fn: (b: BenchContext) => void | Promise; - /** The name of the test, which will be used in displaying the results. */ - name: string; - /** If truthy, the benchmark test will be ignored/skipped. */ - ignore?: boolean; - /** Group name for the benchmark. - * - * Grouped benchmarks produce a group time summary, where the difference - * in performance between each test of the group is compared. */ - group?: string; - /** Benchmark should be used as the baseline for other benchmarks. - * - * If there are multiple baselines in a group, the first one is used as the - * baseline. */ - baseline?: boolean; - /** If at least one bench has `only` set to true, only run benches that have - * `only` set to `true` and fail the bench suite. */ - only?: boolean; - /** Number of iterations to perform. - * @remarks When the benchmark is very fast, this will only be used as a - * suggestion in order to get a more accurate measurement. - */ - n?: number; - /** Number of warmups to do before running the benchmark. - * @remarks A warmup will always be performed even if this is `0` in order to - * determine the speed of the benchmark in order to improve the measurement. When - * the benchmark is very fast, this will be used as a suggestion. - */ - warmup?: number; - /** Ensure the bench case does not prematurely cause the process to exit, - * for example via a call to {@linkcode Deno.exit}. - * - * @default {true} */ - sanitizeExit?: boolean; - /** Specifies the permissions that should be used to run the bench. - * - * Set this to `"inherit"` to keep the calling thread's permissions. - * - * Set this to `"none"` to revoke all permissions. - * - * @default {"inherit"} - */ - permissions?: PermissionOptions; - } - - /** - * Register a benchmark test which will be run when `deno bench` is used on - * the command line and the containing module looks like a bench module. - * - * If the test function (`fn`) returns a promise or is async, the test runner - * will await resolution to consider the test complete. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.bench({ - * name: "example test", - * fn() { - * assertEquals("world", "world"); - * }, - * }); - * - * Deno.bench({ - * name: "example ignored test", - * ignore: Deno.build.os === "windows", - * fn() { - * // This test is ignored only on Windows machines - * }, - * }); - * - * Deno.bench({ - * name: "example async test", - * async fn() { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * } - * }); - * ``` - * - * @category Testing - */ - export function bench(b: BenchDefinition): void; - - /** - * Register a benchmark test which will be run when `deno bench` is used on - * the command line and the containing module looks like a bench module. - * - * If the test function (`fn`) returns a promise or is async, the test runner - * will await resolution to consider the test complete. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.bench("My test description", () => { - * assertEquals("hello", "hello"); - * }); - * - * Deno.bench("My async test description", async () => { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * }); - * ``` - * - * @category Testing - */ - export function bench( - name: string, - fn: (b: BenchContext) => void | Promise, - ): void; - - /** - * Register a benchmark test which will be run when `deno bench` is used on - * the command line and the containing module looks like a bench module. - * - * If the test function (`fn`) returns a promise or is async, the test runner - * will await resolution to consider the test complete. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.bench(function myTestName() { - * assertEquals("hello", "hello"); - * }); - * - * Deno.bench(async function myOtherTestName() { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * }); - * ``` - * - * @category Testing - */ - export function bench(fn: (b: BenchContext) => void | Promise): void; - - /** - * Register a benchmark test which will be run when `deno bench` is used on - * the command line and the containing module looks like a bench module. - * - * If the test function (`fn`) returns a promise or is async, the test runner - * will await resolution to consider the test complete. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.bench( - * "My test description", - * { permissions: { read: true } }, - * () => { - * assertEquals("hello", "hello"); - * } - * ); - * - * Deno.bench( - * "My async test description", - * { permissions: { read: false } }, - * async () => { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * } - * ); - * ``` - * - * @category Testing - */ - export function bench( - name: string, - options: Omit, - fn: (b: BenchContext) => void | Promise, - ): void; - - /** - * Register a benchmark test which will be run when `deno bench` is used on - * the command line and the containing module looks like a bench module. - * - * If the test function (`fn`) returns a promise or is async, the test runner - * will await resolution to consider the test complete. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.bench( - * { name: "My test description", permissions: { read: true } }, - * () => { - * assertEquals("hello", "hello"); - * } - * ); - * - * Deno.bench( - * { name: "My async test description", permissions: { read: false } }, - * async () => { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * } - * ); - * ``` - * - * @category Testing - */ - export function bench( - options: Omit, - fn: (b: BenchContext) => void | Promise, - ): void; - - /** - * Register a benchmark test which will be run when `deno bench` is used on - * the command line and the containing module looks like a bench module. - * - * If the test function (`fn`) returns a promise or is async, the test runner - * will await resolution to consider the test complete. - * - * ```ts - * import { assertEquals } from "jsr:@std/assert"; - * - * Deno.bench( - * { permissions: { read: true } }, - * function myTestName() { - * assertEquals("hello", "hello"); - * } - * ); - * - * Deno.bench( - * { permissions: { read: false } }, - * async function myOtherTestName() { - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello_world.txt"); - * assertEquals(decoder.decode(data), "Hello world"); - * } - * ); - * ``` - * - * @category Testing - */ - export function bench( - options: Omit, - fn: (b: BenchContext) => void | Promise, - ): void; - - /** Exit the Deno process with optional exit code. - * - * If no exit code is supplied then Deno will exit with return code of `0`. - * - * In worker contexts this is an alias to `self.close();`. - * - * ```ts - * Deno.exit(5); - * ``` - * - * @category Runtime - */ - export function exit(code?: number): never; - - /** The exit code for the Deno process. - * - * If no exit code has been supplied, then Deno will assume a return code of `0`. - * - * When setting an exit code value, a number or non-NaN string must be provided, - * otherwise a TypeError will be thrown. - * - * ```ts - * console.log(Deno.exitCode); //-> 0 - * Deno.exitCode = 1; - * console.log(Deno.exitCode); //-> 1 - * ``` - * - * @category Runtime - */ - export var exitCode: number; - - /** An interface containing methods to interact with the process environment - * variables. - * - * @tags allow-env - * @category Runtime - */ - export interface Env { - /** Retrieve the value of an environment variable. - * - * Returns `undefined` if the supplied environment variable is not defined. - * - * ```ts - * console.log(Deno.env.get("HOME")); // e.g. outputs "/home/alice" - * console.log(Deno.env.get("MADE_UP_VAR")); // outputs undefined - * ``` - * - * Requires `allow-env` permission. - * - * @tags allow-env - */ - get(key: string): string | undefined; - - /** Set the value of an environment variable. - * - * ```ts - * Deno.env.set("SOME_VAR", "Value"); - * Deno.env.get("SOME_VAR"); // outputs "Value" - * ``` - * - * Requires `allow-env` permission. - * - * @tags allow-env - */ - set(key: string, value: string): void; - - /** Delete the value of an environment variable. - * - * ```ts - * Deno.env.set("SOME_VAR", "Value"); - * Deno.env.delete("SOME_VAR"); // outputs "undefined" - * ``` - * - * Requires `allow-env` permission. - * - * @tags allow-env - */ - delete(key: string): void; - - /** Check whether an environment variable is present or not. - * - * ```ts - * Deno.env.set("SOME_VAR", "Value"); - * Deno.env.has("SOME_VAR"); // outputs true - * ``` - * - * Requires `allow-env` permission. - * - * @tags allow-env - */ - has(key: string): boolean; - - /** Returns a snapshot of the environment variables at invocation as a - * simple object of keys and values. - * - * ```ts - * Deno.env.set("TEST_VAR", "A"); - * const myEnv = Deno.env.toObject(); - * console.log(myEnv.SHELL); - * Deno.env.set("TEST_VAR", "B"); - * console.log(myEnv.TEST_VAR); // outputs "A" - * ``` - * - * Requires `allow-env` permission. - * - * @tags allow-env - */ - toObject(): { [index: string]: string }; - } - - /** An interface containing methods to interact with the process environment - * variables. - * - * @tags allow-env - * @category Runtime - */ - export const env: Env; - - /** - * Returns the path to the current deno executable. - * - * ```ts - * console.log(Deno.execPath()); // e.g. "/home/alice/.local/bin/deno" - * ``` - * - * @category Runtime - */ - export function execPath(): string; - - /** - * Change the current working directory to the specified path. - * - * ```ts - * Deno.chdir("/home/userA"); - * Deno.chdir("../userB"); - * Deno.chdir("C:\\Program Files (x86)\\Java"); - * ``` - * - * Throws {@linkcode Deno.errors.NotFound} if directory not found. - * - * Throws {@linkcode Deno.errors.PermissionDenied} if the user does not have - * operating system file access rights. - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category Runtime - */ - export function chdir(directory: string | URL): void; - - /** - * Return a string representing the current working directory. - * - * If the current directory can be reached via multiple paths (due to symbolic - * links), `cwd()` may return any one of them. - * - * ```ts - * const currentWorkingDirectory = Deno.cwd(); - * ``` - * - * Throws {@linkcode Deno.errors.NotFound} if directory not available. - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category Runtime - */ - export function cwd(): string; - - /** - * Creates `newpath` as a hard link to `oldpath`. - * - * ```ts - * await Deno.link("old/name", "new/name"); - * ``` - * - * Requires `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function link(oldpath: string, newpath: string): Promise; - - /** - * Synchronously creates `newpath` as a hard link to `oldpath`. - * - * ```ts - * Deno.linkSync("old/name", "new/name"); - * ``` - * - * Requires `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function linkSync(oldpath: string, newpath: string): void; - - /** - * A enum which defines the seek mode for IO related APIs that support - * seeking. - * - * @category I/O */ - export enum SeekMode { - /* Seek from the start of the file/resource. */ - Start = 0, - /* Seek from the current position within the file/resource. */ - Current = 1, - /* Seek from the end of the current file/resource. */ - End = 2, - } - - /** Open a file and resolve to an instance of {@linkcode Deno.FsFile}. The - * file does not need to previously exist if using the `create` or `createNew` - * open options. The caller may have the resulting file automatically closed - * by the runtime once it's out of scope by declaring the file variable with - * the `using` keyword. - * - * ```ts - * using file = await Deno.open("/foo/bar.txt", { read: true, write: true }); - * // Do work with file - * ``` - * - * Alternatively, the caller may manually close the resource when finished with - * it. - * - * ```ts - * const file = await Deno.open("/foo/bar.txt", { read: true, write: true }); - * // Do work with file - * file.close(); - * ``` - * - * Requires `allow-read` and/or `allow-write` permissions depending on - * options. - * - * @tags allow-read, allow-write - * @category File System - */ - export function open( - path: string | URL, - options?: OpenOptions, - ): Promise; - - /** Synchronously open a file and return an instance of - * {@linkcode Deno.FsFile}. The file does not need to previously exist if - * using the `create` or `createNew` open options. The caller may have the - * resulting file automatically closed by the runtime once it's out of scope - * by declaring the file variable with the `using` keyword. - * - * ```ts - * using file = Deno.openSync("/foo/bar.txt", { read: true, write: true }); - * // Do work with file - * ``` - * - * Alternatively, the caller may manually close the resource when finished with - * it. - * - * ```ts - * const file = Deno.openSync("/foo/bar.txt", { read: true, write: true }); - * // Do work with file - * file.close(); - * ``` - * - * Requires `allow-read` and/or `allow-write` permissions depending on - * options. - * - * @tags allow-read, allow-write - * @category File System - */ - export function openSync(path: string | URL, options?: OpenOptions): FsFile; - - /** Creates a file if none exists or truncates an existing file and resolves to - * an instance of {@linkcode Deno.FsFile}. - * - * ```ts - * const file = await Deno.create("/foo/bar.txt"); - * ``` - * - * Requires `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function create(path: string | URL): Promise; - - /** Creates a file if none exists or truncates an existing file and returns - * an instance of {@linkcode Deno.FsFile}. - * - * ```ts - * const file = Deno.createSync("/foo/bar.txt"); - * ``` - * - * Requires `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function createSync(path: string | URL): FsFile; - - /** The Deno abstraction for reading and writing files. - * - * This is the most straight forward way of handling files within Deno and is - * recommended over using the discrete functions within the `Deno` namespace. - * - * ```ts - * using file = await Deno.open("/foo/bar.txt", { read: true }); - * const fileInfo = await file.stat(); - * if (fileInfo.isFile) { - * const buf = new Uint8Array(100); - * const numberOfBytesRead = await file.read(buf); // 11 bytes - * const text = new TextDecoder().decode(buf); // "hello world" - * } - * ``` - * - * @category File System - */ - export class FsFile implements Disposable { - /** A {@linkcode ReadableStream} instance representing to the byte contents - * of the file. This makes it easy to interoperate with other web streams - * based APIs. - * - * ```ts - * using file = await Deno.open("my_file.txt", { read: true }); - * const decoder = new TextDecoder(); - * for await (const chunk of file.readable) { - * console.log(decoder.decode(chunk)); - * } - * ``` - */ - readonly readable: ReadableStream>; - /** A {@linkcode WritableStream} instance to write the contents of the - * file. This makes it easy to interoperate with other web streams based - * APIs. - * - * ```ts - * const items = ["hello", "world"]; - * using file = await Deno.open("my_file.txt", { write: true }); - * const encoder = new TextEncoder(); - * const writer = file.writable.getWriter(); - * for (const item of items) { - * await writer.write(encoder.encode(item)); - * } - * ``` - */ - readonly writable: WritableStream>; - /** Write the contents of the array buffer (`p`) to the file. - * - * Resolves to the number of bytes written. - * - * **It is not guaranteed that the full buffer will be written in a single - * call.** - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world"); - * using file = await Deno.open("/foo/bar.txt", { write: true }); - * const bytesWritten = await file.write(data); // 11 - * ``` - * - * @category I/O - */ - write(p: Uint8Array): Promise; - /** Synchronously write the contents of the array buffer (`p`) to the file. - * - * Returns the number of bytes written. - * - * **It is not guaranteed that the full buffer will be written in a single - * call.** - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world"); - * using file = Deno.openSync("/foo/bar.txt", { write: true }); - * const bytesWritten = file.writeSync(data); // 11 - * ``` - */ - writeSync(p: Uint8Array): number; - /** Truncates (or extends) the file to reach the specified `len`. If `len` - * is not specified, then the entire file contents are truncated. - * - * ### Truncate the entire file - * - * ```ts - * using file = await Deno.open("my_file.txt", { write: true }); - * await file.truncate(); - * ``` - * - * ### Truncate part of the file - * - * ```ts - * // if "my_file.txt" contains the text "hello world": - * using file = await Deno.open("my_file.txt", { write: true }); - * await file.truncate(7); - * const buf = new Uint8Array(100); - * await file.read(buf); - * const text = new TextDecoder().decode(buf); // "hello w" - * ``` - */ - truncate(len?: number): Promise; - /** Synchronously truncates (or extends) the file to reach the specified - * `len`. If `len` is not specified, then the entire file contents are - * truncated. - * - * ### Truncate the entire file - * - * ```ts - * using file = Deno.openSync("my_file.txt", { write: true }); - * file.truncateSync(); - * ``` - * - * ### Truncate part of the file - * - * ```ts - * // if "my_file.txt" contains the text "hello world": - * using file = Deno.openSync("my_file.txt", { write: true }); - * file.truncateSync(7); - * const buf = new Uint8Array(100); - * file.readSync(buf); - * const text = new TextDecoder().decode(buf); // "hello w" - * ``` - */ - truncateSync(len?: number): void; - /** Read the file into an array buffer (`p`). - * - * Resolves to either the number of bytes read during the operation or EOF - * (`null`) if there was nothing more to read. - * - * It is possible for a read to successfully return with `0` bytes. This - * does not indicate EOF. - * - * **It is not guaranteed that the full buffer will be read in a single - * call.** - * - * ```ts - * // if "/foo/bar.txt" contains the text "hello world": - * using file = await Deno.open("/foo/bar.txt"); - * const buf = new Uint8Array(100); - * const numberOfBytesRead = await file.read(buf); // 11 bytes - * const text = new TextDecoder().decode(buf); // "hello world" - * ``` - */ - read(p: Uint8Array): Promise; - /** Synchronously read from the file into an array buffer (`p`). - * - * Returns either the number of bytes read during the operation or EOF - * (`null`) if there was nothing more to read. - * - * It is possible for a read to successfully return with `0` bytes. This - * does not indicate EOF. - * - * **It is not guaranteed that the full buffer will be read in a single - * call.** - * - * ```ts - * // if "/foo/bar.txt" contains the text "hello world": - * using file = Deno.openSync("/foo/bar.txt"); - * const buf = new Uint8Array(100); - * const numberOfBytesRead = file.readSync(buf); // 11 bytes - * const text = new TextDecoder().decode(buf); // "hello world" - * ``` - */ - readSync(p: Uint8Array): number | null; - /** Seek to the given `offset` under mode given by `whence`. The call - * resolves to the new position within the resource (bytes from the start). - * - * ```ts - * // Given the file contains "Hello world" text, which is 11 bytes long: - * using file = await Deno.open( - * "hello.txt", - * { read: true, write: true, truncate: true, create: true }, - * ); - * await file.write(new TextEncoder().encode("Hello world")); - * - * // advance cursor 6 bytes - * const cursorPosition = await file.seek(6, Deno.SeekMode.Start); - * console.log(cursorPosition); // 6 - * const buf = new Uint8Array(100); - * await file.read(buf); - * console.log(new TextDecoder().decode(buf)); // "world" - * ``` - * - * The seek modes work as follows: - * - * ```ts - * // Given the file contains "Hello world" text, which is 11 bytes long: - * const file = await Deno.open( - * "hello.txt", - * { read: true, write: true, truncate: true, create: true }, - * ); - * await file.write(new TextEncoder().encode("Hello world")); - * - * // Seek 6 bytes from the start of the file - * console.log(await file.seek(6, Deno.SeekMode.Start)); // "6" - * // Seek 2 more bytes from the current position - * console.log(await file.seek(2, Deno.SeekMode.Current)); // "8" - * // Seek backwards 2 bytes from the end of the file - * console.log(await file.seek(-2, Deno.SeekMode.End)); // "9" (i.e. 11-2) - * ``` - */ - seek(offset: number | bigint, whence: SeekMode): Promise; - /** Synchronously seek to the given `offset` under mode given by `whence`. - * The new position within the resource (bytes from the start) is returned. - * - * ```ts - * using file = Deno.openSync( - * "hello.txt", - * { read: true, write: true, truncate: true, create: true }, - * ); - * file.writeSync(new TextEncoder().encode("Hello world")); - * - * // advance cursor 6 bytes - * const cursorPosition = file.seekSync(6, Deno.SeekMode.Start); - * console.log(cursorPosition); // 6 - * const buf = new Uint8Array(100); - * file.readSync(buf); - * console.log(new TextDecoder().decode(buf)); // "world" - * ``` - * - * The seek modes work as follows: - * - * ```ts - * // Given the file contains "Hello world" text, which is 11 bytes long: - * using file = Deno.openSync( - * "hello.txt", - * { read: true, write: true, truncate: true, create: true }, - * ); - * file.writeSync(new TextEncoder().encode("Hello world")); - * - * // Seek 6 bytes from the start of the file - * console.log(file.seekSync(6, Deno.SeekMode.Start)); // "6" - * // Seek 2 more bytes from the current position - * console.log(file.seekSync(2, Deno.SeekMode.Current)); // "8" - * // Seek backwards 2 bytes from the end of the file - * console.log(file.seekSync(-2, Deno.SeekMode.End)); // "9" (i.e. 11-2) - * ``` - */ - seekSync(offset: number | bigint, whence: SeekMode): number; - /** Resolves to a {@linkcode Deno.FileInfo} for the file. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * - * using file = await Deno.open("hello.txt"); - * const fileInfo = await file.stat(); - * assert(fileInfo.isFile); - * ``` - */ - stat(): Promise; - /** Synchronously returns a {@linkcode Deno.FileInfo} for the file. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * - * using file = Deno.openSync("hello.txt") - * const fileInfo = file.statSync(); - * assert(fileInfo.isFile); - * ``` - */ - statSync(): FileInfo; - /** - * Flushes any pending data and metadata operations of the given file - * stream to disk. - * - * ```ts - * const file = await Deno.open( - * "my_file.txt", - * { read: true, write: true, create: true }, - * ); - * await file.write(new TextEncoder().encode("Hello World")); - * await file.truncate(1); - * await file.sync(); - * console.log(await Deno.readTextFile("my_file.txt")); // H - * ``` - * - * @category I/O - */ - sync(): Promise; - /** - * Synchronously flushes any pending data and metadata operations of the given - * file stream to disk. - * - * ```ts - * const file = Deno.openSync( - * "my_file.txt", - * { read: true, write: true, create: true }, - * ); - * file.writeSync(new TextEncoder().encode("Hello World")); - * file.truncateSync(1); - * file.syncSync(); - * console.log(Deno.readTextFileSync("my_file.txt")); // H - * ``` - * - * @category I/O - */ - syncSync(): void; - /** - * Flushes any pending data operations of the given file stream to disk. - * ```ts - * using file = await Deno.open( - * "my_file.txt", - * { read: true, write: true, create: true }, - * ); - * await file.write(new TextEncoder().encode("Hello World")); - * await file.syncData(); - * console.log(await Deno.readTextFile("my_file.txt")); // Hello World - * ``` - * - * @category I/O - */ - syncData(): Promise; - /** - * Synchronously flushes any pending data operations of the given file stream - * to disk. - * - * ```ts - * using file = Deno.openSync( - * "my_file.txt", - * { read: true, write: true, create: true }, - * ); - * file.writeSync(new TextEncoder().encode("Hello World")); - * file.syncDataSync(); - * console.log(Deno.readTextFileSync("my_file.txt")); // Hello World - * ``` - * - * @category I/O - */ - syncDataSync(): void; - /** - * Changes the access (`atime`) and modification (`mtime`) times of the - * file stream resource. Given times are either in seconds (UNIX epoch - * time) or as `Date` objects. - * - * ```ts - * using file = await Deno.open("file.txt", { create: true, write: true }); - * await file.utime(1556495550, new Date()); - * ``` - * - * @category File System - */ - utime(atime: number | Date, mtime: number | Date): Promise; - /** - * Synchronously changes the access (`atime`) and modification (`mtime`) - * times of the file stream resource. Given times are either in seconds - * (UNIX epoch time) or as `Date` objects. - * - * ```ts - * using file = Deno.openSync("file.txt", { create: true, write: true }); - * file.utime(1556495550, new Date()); - * ``` - * - * @category File System - */ - utimeSync(atime: number | Date, mtime: number | Date): void; - /** - * Checks if the file resource is a TTY (terminal). - * - * ```ts - * // This example is system and context specific - * using file = await Deno.open("/dev/tty6"); - * file.isTerminal(); // true - * ``` - */ - isTerminal(): boolean; - /** - * Set TTY to be under raw mode or not. In raw mode, characters are read and - * returned as is, without being processed. All special processing of - * characters by the terminal is disabled, including echoing input - * characters. Reading from a TTY device in raw mode is faster than reading - * from a TTY device in canonical mode. - * - * ```ts - * using file = await Deno.open("/dev/tty6"); - * file.setRaw(true, { cbreak: true }); - * ``` - */ - setRaw(mode: boolean, options?: SetRawOptions): void; - /** - * Acquire an advisory file-system lock for the file. - * - * @param [exclusive=false] - */ - lock(exclusive?: boolean): Promise; - /** - * Synchronously acquire an advisory file-system lock synchronously for the file. - * - * @param [exclusive=false] - */ - lockSync(exclusive?: boolean): void; - /** - * Release an advisory file-system lock for the file. - */ - unlock(): Promise; - /** - * Synchronously release an advisory file-system lock for the file. - */ - unlockSync(): void; - /** Close the file. Closing a file when you are finished with it is - * important to avoid leaking resources. - * - * ```ts - * using file = await Deno.open("my_file.txt"); - * // do work with "file" object - * ``` - */ - close(): void; - - [Symbol.dispose](): void; - } - - /** Gets the size of the console as columns/rows. - * - * ```ts - * const { columns, rows } = Deno.consoleSize(); - * ``` - * - * This returns the size of the console window as reported by the operating - * system. It's not a reflection of how many characters will fit within the - * console window, but can be used as part of that calculation. - * - * @category I/O - */ - export function consoleSize(): { - columns: number; - rows: number; - }; - - /** @category I/O */ - export interface SetRawOptions { - /** - * The `cbreak` option can be used to indicate that characters that - * correspond to a signal should still be generated. When disabling raw - * mode, this option is ignored. This functionality currently only works on - * Linux and Mac OS. - */ - cbreak: boolean; - } - - /** A reference to `stdin` which can be used to read directly from `stdin`. - * - * It implements the Deno specific - * {@linkcode https://jsr.io/@std/io/doc/types/~/Reader | Reader}, - * {@linkcode https://jsr.io/@std/io/doc/types/~/ReaderSync | ReaderSync}, - * and {@linkcode https://jsr.io/@std/io/doc/types/~/Closer | Closer} - * interfaces as well as provides a {@linkcode ReadableStream} interface. - * - * ### Reading chunks from the readable stream - * - * ```ts - * const decoder = new TextDecoder(); - * for await (const chunk of Deno.stdin.readable) { - * const text = decoder.decode(chunk); - * // do something with the text - * } - * ``` - * - * @category I/O - */ - export const stdin: { - /** Read the incoming data from `stdin` into an array buffer (`p`). - * - * Resolves to either the number of bytes read during the operation or EOF - * (`null`) if there was nothing more to read. - * - * It is possible for a read to successfully return with `0` bytes. This - * does not indicate EOF. - * - * **It is not guaranteed that the full buffer will be read in a single - * call.** - * - * ```ts - * // If the text "hello world" is piped into the script: - * const buf = new Uint8Array(100); - * const numberOfBytesRead = await Deno.stdin.read(buf); // 11 bytes - * const text = new TextDecoder().decode(buf); // "hello world" - * ``` - * - * @category I/O - */ - read(p: Uint8Array): Promise; - /** Synchronously read from the incoming data from `stdin` into an array - * buffer (`p`). - * - * Returns either the number of bytes read during the operation or EOF - * (`null`) if there was nothing more to read. - * - * It is possible for a read to successfully return with `0` bytes. This - * does not indicate EOF. - * - * **It is not guaranteed that the full buffer will be read in a single - * call.** - * - * ```ts - * // If the text "hello world" is piped into the script: - * const buf = new Uint8Array(100); - * const numberOfBytesRead = Deno.stdin.readSync(buf); // 11 bytes - * const text = new TextDecoder().decode(buf); // "hello world" - * ``` - * - * @category I/O - */ - readSync(p: Uint8Array): number | null; - /** Closes `stdin`, freeing the resource. - * - * ```ts - * Deno.stdin.close(); - * ``` - */ - close(): void; - /** A readable stream interface to `stdin`. */ - readonly readable: ReadableStream>; - /** - * Set TTY to be under raw mode or not. In raw mode, characters are read and - * returned as is, without being processed. All special processing of - * characters by the terminal is disabled, including echoing input - * characters. Reading from a TTY device in raw mode is faster than reading - * from a TTY device in canonical mode. - * - * ```ts - * Deno.stdin.setRaw(true, { cbreak: true }); - * ``` - * - * @category I/O - */ - setRaw(mode: boolean, options?: SetRawOptions): void; - /** - * Checks if `stdin` is a TTY (terminal). - * - * ```ts - * // This example is system and context specific - * Deno.stdin.isTerminal(); // true - * ``` - * - * @category I/O - */ - isTerminal(): boolean; - }; - /** A reference to `stdout` which can be used to write directly to `stdout`. - * It implements the Deno specific - * {@linkcode https://jsr.io/@std/io/doc/types/~/Writer | Writer}, - * {@linkcode https://jsr.io/@std/io/doc/types/~/WriterSync | WriterSync}, - * and {@linkcode https://jsr.io/@std/io/doc/types/~/Closer | Closer} interfaces as well as provides a - * {@linkcode WritableStream} interface. - * - * These are low level constructs, and the {@linkcode console} interface is a - * more straight forward way to interact with `stdout` and `stderr`. - * - * @category I/O - */ - export const stdout: { - /** Write the contents of the array buffer (`p`) to `stdout`. - * - * Resolves to the number of bytes written. - * - * **It is not guaranteed that the full buffer will be written in a single - * call.** - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world"); - * const bytesWritten = await Deno.stdout.write(data); // 11 - * ``` - * - * @category I/O - */ - write(p: Uint8Array): Promise; - /** Synchronously write the contents of the array buffer (`p`) to `stdout`. - * - * Returns the number of bytes written. - * - * **It is not guaranteed that the full buffer will be written in a single - * call.** - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world"); - * const bytesWritten = Deno.stdout.writeSync(data); // 11 - * ``` - */ - writeSync(p: Uint8Array): number; - /** Closes `stdout`, freeing the resource. - * - * ```ts - * Deno.stdout.close(); - * ``` - */ - close(): void; - /** A writable stream interface to `stdout`. */ - readonly writable: WritableStream>; - /** - * Checks if `stdout` is a TTY (terminal). - * - * ```ts - * // This example is system and context specific - * Deno.stdout.isTerminal(); // true - * ``` - * - * @category I/O - */ - isTerminal(): boolean; - }; - /** A reference to `stderr` which can be used to write directly to `stderr`. - * It implements the Deno specific - * {@linkcode https://jsr.io/@std/io/doc/types/~/Writer | Writer}, - * {@linkcode https://jsr.io/@std/io/doc/types/~/WriterSync | WriterSync}, - * and {@linkcode https://jsr.io/@std/io/doc/types/~/Closer | Closer} interfaces as well as provides a - * {@linkcode WritableStream} interface. - * - * These are low level constructs, and the {@linkcode console} interface is a - * more straight forward way to interact with `stdout` and `stderr`. - * - * @category I/O - */ - export const stderr: { - /** Write the contents of the array buffer (`p`) to `stderr`. - * - * Resolves to the number of bytes written. - * - * **It is not guaranteed that the full buffer will be written in a single - * call.** - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world"); - * const bytesWritten = await Deno.stderr.write(data); // 11 - * ``` - * - * @category I/O - */ - write(p: Uint8Array): Promise; - /** Synchronously write the contents of the array buffer (`p`) to `stderr`. - * - * Returns the number of bytes written. - * - * **It is not guaranteed that the full buffer will be written in a single - * call.** - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world"); - * const bytesWritten = Deno.stderr.writeSync(data); // 11 - * ``` - */ - writeSync(p: Uint8Array): number; - /** Closes `stderr`, freeing the resource. - * - * ```ts - * Deno.stderr.close(); - * ``` - */ - close(): void; - /** A writable stream interface to `stderr`. */ - readonly writable: WritableStream>; - /** - * Checks if `stderr` is a TTY (terminal). - * - * ```ts - * // This example is system and context specific - * Deno.stderr.isTerminal(); // true - * ``` - * - * @category I/O - */ - isTerminal(): boolean; - }; - - /** - * Options which can be set when doing {@linkcode Deno.open} and - * {@linkcode Deno.openSync}. - * - * @category File System */ - export interface OpenOptions { - /** Sets the option for read access. This option, when `true`, means that - * the file should be read-able if opened. - * - * @default {true} */ - read?: boolean; - /** Sets the option for write access. This option, when `true`, means that - * the file should be write-able if opened. If the file already exists, - * any write calls on it will overwrite its contents, by default without - * truncating it. - * - * @default {false} */ - write?: boolean; - /** Sets the option for the append mode. This option, when `true`, means - * that writes will append to a file instead of overwriting previous - * contents. - * - * Note that setting `{ write: true, append: true }` has the same effect as - * setting only `{ append: true }`. - * - * @default {false} */ - append?: boolean; - /** Sets the option for truncating a previous file. If a file is - * successfully opened with this option set it will truncate the file to `0` - * size if it already exists. The file must be opened with write access - * for truncate to work. - * - * @default {false} */ - truncate?: boolean; - /** Sets the option to allow creating a new file, if one doesn't already - * exist at the specified path. Requires write or append access to be - * used. - * - * @default {false} */ - create?: boolean; - /** If set to `true`, no file, directory, or symlink is allowed to exist at - * the target location. Requires write or append access to be used. When - * createNew is set to `true`, create and truncate are ignored. - * - * @default {false} */ - createNew?: boolean; - /** Permissions to use if creating the file (defaults to `0o666`, before - * the process's umask). - * - * Ignored on Windows. */ - mode?: number; - } - - /** - * Options which can be set when using {@linkcode Deno.readFile} or - * {@linkcode Deno.readFileSync}. - * - * @category File System */ - export interface ReadFileOptions { - /** - * An abort signal to allow cancellation of the file read operation. - * If the signal becomes aborted the readFile operation will be stopped - * and the promise returned will be rejected with an AbortError. - */ - signal?: AbortSignal; - } - - /** - * Options which can be set when using {@linkcode Deno.mkdir} and - * {@linkcode Deno.mkdirSync}. - * - * @category File System */ - export interface MkdirOptions { - /** If set to `true`, means that any intermediate directories will also be - * created (as with the shell command `mkdir -p`). - * - * Intermediate directories are created with the same permissions. - * - * When recursive is set to `true`, succeeds silently (without changing any - * permissions) if a directory already exists at the path, or if the path - * is a symlink to an existing directory. - * - * @default {false} */ - recursive?: boolean; - /** Permissions to use when creating the directory (defaults to `0o777`, - * before the process's umask). - * - * Ignored on Windows. */ - mode?: number; - } - - /** Creates a new directory with the specified path. - * - * ```ts - * await Deno.mkdir("new_dir"); - * await Deno.mkdir("nested/directories", { recursive: true }); - * await Deno.mkdir("restricted_access_dir", { mode: 0o700 }); - * ``` - * - * Defaults to throwing error if the directory already exists. - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function mkdir( - path: string | URL, - options?: MkdirOptions, - ): Promise; - - /** Synchronously creates a new directory with the specified path. - * - * ```ts - * Deno.mkdirSync("new_dir"); - * Deno.mkdirSync("nested/directories", { recursive: true }); - * Deno.mkdirSync("restricted_access_dir", { mode: 0o700 }); - * ``` - * - * Defaults to throwing error if the directory already exists. - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function mkdirSync(path: string | URL, options?: MkdirOptions): void; - - /** - * Options which can be set when using {@linkcode Deno.makeTempDir}, - * {@linkcode Deno.makeTempDirSync}, {@linkcode Deno.makeTempFile}, and - * {@linkcode Deno.makeTempFileSync}. - * - * @category File System */ - export interface MakeTempOptions { - /** Directory where the temporary directory should be created (defaults to - * the env variable `TMPDIR`, or the system's default, usually `/tmp`). - * - * Note that if the passed `dir` is relative, the path returned by - * `makeTempFile()` and `makeTempDir()` will also be relative. Be mindful of - * this when changing working directory. */ - dir?: string; - /** String that should precede the random portion of the temporary - * directory's name. */ - prefix?: string; - /** String that should follow the random portion of the temporary - * directory's name. */ - suffix?: string; - } - - /** Creates a new temporary directory in the default directory for temporary - * files, unless `dir` is specified. Other optional options include - * prefixing and suffixing the directory name with `prefix` and `suffix` - * respectively. - * - * This call resolves to the full path to the newly created directory. - * - * Multiple programs calling this function simultaneously will create different - * directories. It is the caller's responsibility to remove the directory when - * no longer needed. - * - * ```ts - * const tempDirName0 = await Deno.makeTempDir(); // e.g. /tmp/2894ea76 - * const tempDirName1 = await Deno.makeTempDir({ prefix: 'my_temp' }); // e.g. /tmp/my_temp339c944d - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - // TODO(ry) Doesn't check permissions. - export function makeTempDir(options?: MakeTempOptions): Promise; - - /** Synchronously creates a new temporary directory in the default directory - * for temporary files, unless `dir` is specified. Other optional options - * include prefixing and suffixing the directory name with `prefix` and - * `suffix` respectively. - * - * The full path to the newly created directory is returned. - * - * Multiple programs calling this function simultaneously will create different - * directories. It is the caller's responsibility to remove the directory when - * no longer needed. - * - * ```ts - * const tempDirName0 = Deno.makeTempDirSync(); // e.g. /tmp/2894ea76 - * const tempDirName1 = Deno.makeTempDirSync({ prefix: 'my_temp' }); // e.g. /tmp/my_temp339c944d - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - // TODO(ry) Doesn't check permissions. - export function makeTempDirSync(options?: MakeTempOptions): string; - - /** Creates a new temporary file in the default directory for temporary - * files, unless `dir` is specified. - * - * Other options include prefixing and suffixing the directory name with - * `prefix` and `suffix` respectively. - * - * This call resolves to the full path to the newly created file. - * - * Multiple programs calling this function simultaneously will create - * different files. It is the caller's responsibility to remove the file when - * no longer needed. - * - * ```ts - * const tmpFileName0 = await Deno.makeTempFile(); // e.g. /tmp/419e0bf2 - * const tmpFileName1 = await Deno.makeTempFile({ prefix: 'my_temp' }); // e.g. /tmp/my_temp754d3098 - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function makeTempFile(options?: MakeTempOptions): Promise; - - /** Synchronously creates a new temporary file in the default directory for - * temporary files, unless `dir` is specified. - * - * Other options include prefixing and suffixing the directory name with - * `prefix` and `suffix` respectively. - * - * The full path to the newly created file is returned. - * - * Multiple programs calling this function simultaneously will create - * different files. It is the caller's responsibility to remove the file when - * no longer needed. - * - * ```ts - * const tempFileName0 = Deno.makeTempFileSync(); // e.g. /tmp/419e0bf2 - * const tempFileName1 = Deno.makeTempFileSync({ prefix: 'my_temp' }); // e.g. /tmp/my_temp754d3098 - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function makeTempFileSync(options?: MakeTempOptions): string; - - /** Changes the permission of a specific file/directory of specified path. - * Ignores the process's umask. - * - * ```ts - * await Deno.chmod("/path/to/file", 0o666); - * ``` - * - * The mode is a sequence of 3 octal numbers. The first/left-most number - * specifies the permissions for the owner. The second number specifies the - * permissions for the group. The last/right-most number specifies the - * permissions for others. For example, with a mode of 0o764, the owner (7) - * can read/write/execute, the group (6) can read/write and everyone else (4) - * can read only. - * - * | Number | Description | - * | ------ | ----------- | - * | 7 | read, write, and execute | - * | 6 | read and write | - * | 5 | read and execute | - * | 4 | read only | - * | 3 | write and execute | - * | 2 | write only | - * | 1 | execute only | - * | 0 | no permission | - * - * Note: On Windows, only the read and write permissions can be modified. - * Distinctions between owner, group, and others are not supported. - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function chmod(path: string | URL, mode: number): Promise; - - /** Synchronously changes the permission of a specific file/directory of - * specified path. Ignores the process's umask. - * - * ```ts - * Deno.chmodSync("/path/to/file", 0o666); - * ``` - * - * For a full description, see {@linkcode Deno.chmod}. - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function chmodSync(path: string | URL, mode: number): void; - - /** Change owner of a regular file or directory. - * - * This functionality is not available on Windows. - * - * ```ts - * await Deno.chown("myFile.txt", 1000, 1002); - * ``` - * - * Requires `allow-write` permission. - * - * Throws Error (not implemented) if executed on Windows. - * - * @tags allow-write - * @category File System - * - * @param path path to the file - * @param uid user id (UID) of the new owner, or `null` for no change - * @param gid group id (GID) of the new owner, or `null` for no change - */ - export function chown( - path: string | URL, - uid: number | null, - gid: number | null, - ): Promise; - - /** Synchronously change owner of a regular file or directory. - * - * This functionality is not available on Windows. - * - * ```ts - * Deno.chownSync("myFile.txt", 1000, 1002); - * ``` - * - * Requires `allow-write` permission. - * - * Throws Error (not implemented) if executed on Windows. - * - * @tags allow-write - * @category File System - * - * @param path path to the file - * @param uid user id (UID) of the new owner, or `null` for no change - * @param gid group id (GID) of the new owner, or `null` for no change - */ - export function chownSync( - path: string | URL, - uid: number | null, - gid: number | null, - ): void; - - /** - * Options which can be set when using {@linkcode Deno.remove} and - * {@linkcode Deno.removeSync}. - * - * @category File System */ - export interface RemoveOptions { - /** If set to `true`, path will be removed even if it's a non-empty directory. - * - * @default {false} */ - recursive?: boolean; - } - - /** Removes the named file or directory. - * - * ```ts - * await Deno.remove("/path/to/empty_dir/or/file"); - * await Deno.remove("/path/to/populated_dir/or/file", { recursive: true }); - * ``` - * - * Throws error if permission denied, path not found, or path is a non-empty - * directory and the `recursive` option isn't set to `true`. - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function remove( - path: string | URL, - options?: RemoveOptions, - ): Promise; - - /** Synchronously removes the named file or directory. - * - * ```ts - * Deno.removeSync("/path/to/empty_dir/or/file"); - * Deno.removeSync("/path/to/populated_dir/or/file", { recursive: true }); - * ``` - * - * Throws error if permission denied, path not found, or path is a non-empty - * directory and the `recursive` option isn't set to `true`. - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function removeSync(path: string | URL, options?: RemoveOptions): void; - - /** Synchronously renames (moves) `oldpath` to `newpath`. Paths may be files or - * directories. If `newpath` already exists and is not a directory, - * `renameSync()` replaces it. OS-specific restrictions may apply when - * `oldpath` and `newpath` are in different directories. - * - * ```ts - * Deno.renameSync("old/path", "new/path"); - * ``` - * - * On Unix-like OSes, this operation does not follow symlinks at either path. - * - * It varies between platforms when the operation throws errors, and if so what - * they are. It's always an error to rename anything to a non-empty directory. - * - * Requires `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function renameSync( - oldpath: string | URL, - newpath: string | URL, - ): void; - - /** Renames (moves) `oldpath` to `newpath`. Paths may be files or directories. - * If `newpath` already exists and is not a directory, `rename()` replaces it. - * OS-specific restrictions may apply when `oldpath` and `newpath` are in - * different directories. - * - * ```ts - * await Deno.rename("old/path", "new/path"); - * ``` - * - * On Unix-like OSes, this operation does not follow symlinks at either path. - * - * It varies between platforms when the operation throws errors, and if so - * what they are. It's always an error to rename anything to a non-empty - * directory. - * - * Requires `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function rename( - oldpath: string | URL, - newpath: string | URL, - ): Promise; - - /** Asynchronously reads and returns the entire contents of a file as an UTF-8 - * decoded string. Reading a directory throws an error. - * - * ```ts - * const data = await Deno.readTextFile("hello.txt"); - * console.log(data); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readTextFile( - path: string | URL, - options?: ReadFileOptions, - ): Promise; - - /** Synchronously reads and returns the entire contents of a file as an UTF-8 - * decoded string. Reading a directory throws an error. - * - * ```ts - * const data = Deno.readTextFileSync("hello.txt"); - * console.log(data); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readTextFileSync(path: string | URL): string; - - /** Reads and resolves to the entire contents of a file as an array of bytes. - * `TextDecoder` can be used to transform the bytes to string if required. - * Rejects with an error when reading a directory. - * - * ```ts - * const decoder = new TextDecoder("utf-8"); - * const data = await Deno.readFile("hello.txt"); - * console.log(decoder.decode(data)); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readFile( - path: string | URL, - options?: ReadFileOptions, - ): Promise>; - - /** Synchronously reads and returns the entire contents of a file as an array - * of bytes. `TextDecoder` can be used to transform the bytes to string if - * required. Throws an error when reading a directory. - * - * ```ts - * const decoder = new TextDecoder("utf-8"); - * const data = Deno.readFileSync("hello.txt"); - * console.log(decoder.decode(data)); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readFileSync(path: string | URL): Uint8Array; - - /** Provides information about a file and is returned by - * {@linkcode Deno.stat}, {@linkcode Deno.lstat}, {@linkcode Deno.statSync}, - * and {@linkcode Deno.lstatSync} or from calling `stat()` and `statSync()` - * on an {@linkcode Deno.FsFile} instance. - * - * @category File System - */ - export interface FileInfo { - /** True if this is info for a regular file. Mutually exclusive to - * `FileInfo.isDirectory` and `FileInfo.isSymlink`. */ - isFile: boolean; - /** True if this is info for a regular directory. Mutually exclusive to - * `FileInfo.isFile` and `FileInfo.isSymlink`. */ - isDirectory: boolean; - /** True if this is info for a symlink. Mutually exclusive to - * `FileInfo.isFile` and `FileInfo.isDirectory`. */ - isSymlink: boolean; - /** The size of the file, in bytes. */ - size: number; - /** The last modification time of the file. This corresponds to the `mtime` - * field from `stat` on Linux/Mac OS and `ftLastWriteTime` on Windows. This - * may not be available on all platforms. */ - mtime: Date | null; - /** The last access time of the file. This corresponds to the `atime` - * field from `stat` on Unix and `ftLastAccessTime` on Windows. This may not - * be available on all platforms. */ - atime: Date | null; - /** The creation time of the file. This corresponds to the `birthtime` - * field from `stat` on Mac/BSD and `ftCreationTime` on Windows. This may - * not be available on all platforms. */ - birthtime: Date | null; - /** The last change time of the file. This corresponds to the `ctime` - * field from `stat` on Mac/BSD and `ChangeTime` on Windows. This may - * not be available on all platforms. */ - ctime: Date | null; - /** ID of the device containing the file. */ - dev: number; - /** Corresponds to the inode number on Unix systems. On Windows, this is - * the file index number that is unique within a volume. This may not be - * available on all platforms. */ - ino: number | null; - /** The underlying raw `st_mode` bits that contain the standard Unix - * permissions for this file/directory. - */ - mode: number | null; - /** Number of hard links pointing to this file. */ - nlink: number | null; - /** User ID of the owner of this file. - * - * _Linux/Mac OS only._ */ - uid: number | null; - /** Group ID of the owner of this file. - * - * _Linux/Mac OS only._ */ - gid: number | null; - /** Device ID of this file. - * - * _Linux/Mac OS only._ */ - rdev: number | null; - /** Blocksize for filesystem I/O. - * - * _Linux/Mac OS only._ */ - blksize: number | null; - /** Number of blocks allocated to the file, in 512-byte units. */ - blocks: number | null; - /** True if this is info for a block device. - * - * _Linux/Mac OS only._ */ - isBlockDevice: boolean | null; - /** True if this is info for a char device. - * - * _Linux/Mac OS only._ */ - isCharDevice: boolean | null; - /** True if this is info for a fifo. - * - * _Linux/Mac OS only._ */ - isFifo: boolean | null; - /** True if this is info for a socket. - * - * _Linux/Mac OS only._ */ - isSocket: boolean | null; - } - - /** Resolves to the absolute normalized path, with symbolic links resolved. - * - * ```ts - * // e.g. given /home/alice/file.txt and current directory /home/alice - * await Deno.symlink("file.txt", "symlink_file.txt"); - * const realPath = await Deno.realPath("./file.txt"); - * const realSymLinkPath = await Deno.realPath("./symlink_file.txt"); - * console.log(realPath); // outputs "/home/alice/file.txt" - * console.log(realSymLinkPath); // outputs "/home/alice/file.txt" - * ``` - * - * Requires `allow-read` permission for the target path. - * - * Also requires `allow-read` permission for the `CWD` if the target path is - * relative. - * - * @tags allow-read - * @category File System - */ - export function realPath(path: string | URL): Promise; - - /** Synchronously returns absolute normalized path, with symbolic links - * resolved. - * - * ```ts - * // e.g. given /home/alice/file.txt and current directory /home/alice - * Deno.symlinkSync("file.txt", "symlink_file.txt"); - * const realPath = Deno.realPathSync("./file.txt"); - * const realSymLinkPath = Deno.realPathSync("./symlink_file.txt"); - * console.log(realPath); // outputs "/home/alice/file.txt" - * console.log(realSymLinkPath); // outputs "/home/alice/file.txt" - * ``` - * - * Requires `allow-read` permission for the target path. - * - * Also requires `allow-read` permission for the `CWD` if the target path is - * relative. - * - * @tags allow-read - * @category File System - */ - export function realPathSync(path: string | URL): string; - - /** - * Information about a directory entry returned from {@linkcode Deno.readDir} - * and {@linkcode Deno.readDirSync}. - * - * @category File System */ - export interface DirEntry { - /** The file name of the entry. It is just the entity name and does not - * include the full path. */ - name: string; - /** True if this is info for a regular file. Mutually exclusive to - * `DirEntry.isDirectory` and `DirEntry.isSymlink`. */ - isFile: boolean; - /** True if this is info for a regular directory. Mutually exclusive to - * `DirEntry.isFile` and `DirEntry.isSymlink`. */ - isDirectory: boolean; - /** True if this is info for a symlink. Mutually exclusive to - * `DirEntry.isFile` and `DirEntry.isDirectory`. */ - isSymlink: boolean; - } - - /** Reads the directory given by `path` and returns an async iterable of - * {@linkcode Deno.DirEntry}. The order of entries is not guaranteed. - * - * ```ts - * for await (const dirEntry of Deno.readDir("/")) { - * console.log(dirEntry.name); - * } - * ``` - * - * Throws error if `path` is not a directory. - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readDir(path: string | URL): AsyncIterable; - - /** Synchronously reads the directory given by `path` and returns an iterable - * of {@linkcode Deno.DirEntry}. The order of entries is not guaranteed. - * - * ```ts - * for (const dirEntry of Deno.readDirSync("/")) { - * console.log(dirEntry.name); - * } - * ``` - * - * Throws error if `path` is not a directory. - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readDirSync(path: string | URL): IteratorObject; - - /** Copies the contents and permissions of one file to another specified path, - * by default creating a new file if needed, else overwriting. Fails if target - * path is a directory or is unwritable. - * - * ```ts - * await Deno.copyFile("from.txt", "to.txt"); - * ``` - * - * Requires `allow-read` permission on `fromPath`. - * - * Requires `allow-write` permission on `toPath`. - * - * @tags allow-read, allow-write - * @category File System - */ - export function copyFile( - fromPath: string | URL, - toPath: string | URL, - ): Promise; - - /** Synchronously copies the contents and permissions of one file to another - * specified path, by default creating a new file if needed, else overwriting. - * Fails if target path is a directory or is unwritable. - * - * ```ts - * Deno.copyFileSync("from.txt", "to.txt"); - * ``` - * - * Requires `allow-read` permission on `fromPath`. - * - * Requires `allow-write` permission on `toPath`. - * - * @tags allow-read, allow-write - * @category File System - */ - export function copyFileSync( - fromPath: string | URL, - toPath: string | URL, - ): void; - - /** Resolves to the full path destination of the named symbolic link. - * - * ```ts - * await Deno.symlink("./test.txt", "./test_link.txt"); - * const target = await Deno.readLink("./test_link.txt"); // full path of ./test.txt - * ``` - * - * Throws TypeError if called with a hard link. - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readLink(path: string | URL): Promise; - - /** Synchronously returns the full path destination of the named symbolic - * link. - * - * ```ts - * Deno.symlinkSync("./test.txt", "./test_link.txt"); - * const target = Deno.readLinkSync("./test_link.txt"); // full path of ./test.txt - * ``` - * - * Throws TypeError if called with a hard link. - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function readLinkSync(path: string | URL): string; - - /** Resolves to a {@linkcode Deno.FileInfo} for the specified `path`. If - * `path` is a symlink, information for the symlink will be returned instead - * of what it points to. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * const fileInfo = await Deno.lstat("hello.txt"); - * assert(fileInfo.isFile); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function lstat(path: string | URL): Promise; - - /** Synchronously returns a {@linkcode Deno.FileInfo} for the specified - * `path`. If `path` is a symlink, information for the symlink will be - * returned instead of what it points to. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * const fileInfo = Deno.lstatSync("hello.txt"); - * assert(fileInfo.isFile); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function lstatSync(path: string | URL): FileInfo; - - /** Resolves to a {@linkcode Deno.FileInfo} for the specified `path`. Will - * always follow symlinks. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * const fileInfo = await Deno.stat("hello.txt"); - * assert(fileInfo.isFile); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function stat(path: string | URL): Promise; - - /** Synchronously returns a {@linkcode Deno.FileInfo} for the specified - * `path`. Will always follow symlinks. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * const fileInfo = Deno.statSync("hello.txt"); - * assert(fileInfo.isFile); - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function statSync(path: string | URL): FileInfo; - - /** Options for writing to a file. - * - * @category File System - */ - export interface WriteFileOptions { - /** If set to `true`, will append to a file instead of overwriting previous - * contents. - * - * @default {false} */ - append?: boolean; - /** Sets the option to allow creating a new file, if one doesn't already - * exist at the specified path. - * - * @default {true} */ - create?: boolean; - /** If set to `true`, no file, directory, or symlink is allowed to exist at - * the target location. When createNew is set to `true`, `create` is ignored. - * - * @default {false} */ - createNew?: boolean; - /** Permissions always applied to file. */ - mode?: number; - /** An abort signal to allow cancellation of the file write operation. - * - * If the signal becomes aborted the write file operation will be stopped - * and the promise returned will be rejected with an {@linkcode AbortError}. - */ - signal?: AbortSignal; - } - - /** Write `data` to the given `path`, by default creating a new file if - * needed, else overwriting. - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world\n"); - * await Deno.writeFile("hello1.txt", data); // overwrite "hello1.txt" or create it - * await Deno.writeFile("hello2.txt", data, { create: false }); // only works if "hello2.txt" exists - * await Deno.writeFile("hello3.txt", data, { mode: 0o777 }); // set permissions on new file - * await Deno.writeFile("hello4.txt", data, { append: true }); // add data to the end of the file - * ``` - * - * Requires `allow-write` permission, and `allow-read` if `options.create` is - * `false`. - * - * @tags allow-read, allow-write - * @category File System - */ - export function writeFile( - path: string | URL, - data: Uint8Array | ReadableStream, - options?: WriteFileOptions, - ): Promise; - - /** Synchronously write `data` to the given `path`, by default creating a new - * file if needed, else overwriting. - * - * ```ts - * const encoder = new TextEncoder(); - * const data = encoder.encode("Hello world\n"); - * Deno.writeFileSync("hello1.txt", data); // overwrite "hello1.txt" or create it - * Deno.writeFileSync("hello2.txt", data, { create: false }); // only works if "hello2.txt" exists - * Deno.writeFileSync("hello3.txt", data, { mode: 0o777 }); // set permissions on new file - * Deno.writeFileSync("hello4.txt", data, { append: true }); // add data to the end of the file - * ``` - * - * Requires `allow-write` permission, and `allow-read` if `options.create` is - * `false`. - * - * @tags allow-read, allow-write - * @category File System - */ - export function writeFileSync( - path: string | URL, - data: Uint8Array, - options?: WriteFileOptions, - ): void; - - /** Write string `data` to the given `path`, by default creating a new file if - * needed, else overwriting. - * - * ```ts - * await Deno.writeTextFile("hello1.txt", "Hello world\n"); // overwrite "hello1.txt" or create it - * ``` - * - * Requires `allow-write` permission, and `allow-read` if `options.create` is - * `false`. - * - * @tags allow-read, allow-write - * @category File System - */ - export function writeTextFile( - path: string | URL, - data: string | ReadableStream, - options?: WriteFileOptions, - ): Promise; - - /** Synchronously write string `data` to the given `path`, by default creating - * a new file if needed, else overwriting. - * - * ```ts - * Deno.writeTextFileSync("hello1.txt", "Hello world\n"); // overwrite "hello1.txt" or create it - * ``` - * - * Requires `allow-write` permission, and `allow-read` if `options.create` is - * `false`. - * - * @tags allow-read, allow-write - * @category File System - */ - export function writeTextFileSync( - path: string | URL, - data: string, - options?: WriteFileOptions, - ): void; - - /** Truncates (or extends) the specified file, to reach the specified `len`. - * If `len` is not specified then the entire file contents are truncated. - * - * ### Truncate the entire file - * ```ts - * await Deno.truncate("my_file.txt"); - * ``` - * - * ### Truncate part of the file - * - * ```ts - * const file = await Deno.makeTempFile(); - * await Deno.writeTextFile(file, "Hello World"); - * await Deno.truncate(file, 7); - * const data = await Deno.readFile(file); - * console.log(new TextDecoder().decode(data)); // "Hello W" - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function truncate(name: string, len?: number): Promise; - - /** Synchronously truncates (or extends) the specified file, to reach the - * specified `len`. If `len` is not specified then the entire file contents - * are truncated. - * - * ### Truncate the entire file - * - * ```ts - * Deno.truncateSync("my_file.txt"); - * ``` - * - * ### Truncate part of the file - * - * ```ts - * const file = Deno.makeTempFileSync(); - * Deno.writeFileSync(file, new TextEncoder().encode("Hello World")); - * Deno.truncateSync(file, 7); - * const data = Deno.readFileSync(file); - * console.log(new TextDecoder().decode(data)); - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function truncateSync(name: string, len?: number): void; - - /** - * Additional information for FsEvent objects with the "other" kind. - * - * - `"rescan"`: rescan notices indicate either a lapse in the events or a - * change in the filesystem such that events received so far can no longer - * be relied on to represent the state of the filesystem now. An - * application that simply reacts to file changes may not care about this. - * An application that keeps an in-memory representation of the filesystem - * will need to care, and will need to refresh that representation directly - * from the filesystem. - * - * @category File System - */ - export type FsEventFlag = "rescan"; - - /** - * Represents a unique file system event yielded by a - * {@linkcode Deno.FsWatcher}. - * - * @category File System */ - export interface FsEvent { - /** The kind/type of the file system event. */ - kind: - | "any" - | "access" - | "create" - | "modify" - | "rename" - | "remove" - | "other"; - /** An array of paths that are associated with the file system event. */ - paths: string[]; - /** Any additional flags associated with the event. */ - flag?: FsEventFlag; - } - - /** - * Returned by {@linkcode Deno.watchFs}. It is an async iterator yielding up - * system events. To stop watching the file system by calling `.close()` - * method. - * - * @category File System - */ - export interface FsWatcher extends AsyncIterable, Disposable { - /** Stops watching the file system and closes the watcher resource. */ - close(): void; - /** - * Stops watching the file system and closes the watcher resource. - */ - return?(value?: any): Promise>; - [Symbol.asyncIterator](): AsyncIterableIterator; - } - - /** Watch for file system events against one or more `paths`, which can be - * files or directories. These paths must exist already. One user action (e.g. - * `touch test.file`) can generate multiple file system events. Likewise, - * one user action can result in multiple file paths in one event (e.g. `mv - * old_name.txt new_name.txt`). - * - * The recursive option is `true` by default and, for directories, will watch - * the specified directory and all sub directories. - * - * Note that the exact ordering of the events can vary between operating - * systems. - * - * ```ts - * const watcher = Deno.watchFs("/"); - * for await (const event of watcher) { - * console.log(">>>> event", event); - * // { kind: "create", paths: [ "/foo.txt" ] } - * } - * ``` - * - * Call `watcher.close()` to stop watching. - * - * ```ts - * const watcher = Deno.watchFs("/"); - * - * setTimeout(() => { - * watcher.close(); - * }, 5000); - * - * for await (const event of watcher) { - * console.log(">>>> event", event); - * } - * ``` - * - * Requires `allow-read` permission. - * - * @tags allow-read - * @category File System - */ - export function watchFs( - paths: string | string[], - options?: { recursive: boolean }, - ): FsWatcher; - - /** Operating signals which can be listened for or sent to sub-processes. What - * signals and what their standard behaviors are OS dependent. - * - * @category Runtime */ - export type Signal = - | "SIGABRT" - | "SIGALRM" - | "SIGBREAK" - | "SIGBUS" - | "SIGCHLD" - | "SIGCONT" - | "SIGEMT" - | "SIGFPE" - | "SIGHUP" - | "SIGILL" - | "SIGINFO" - | "SIGINT" - | "SIGIO" - | "SIGPOLL" - | "SIGUNUSED" - | "SIGKILL" - | "SIGPIPE" - | "SIGPROF" - | "SIGPWR" - | "SIGQUIT" - | "SIGSEGV" - | "SIGSTKFLT" - | "SIGSTOP" - | "SIGSYS" - | "SIGTERM" - | "SIGTRAP" - | "SIGTSTP" - | "SIGTTIN" - | "SIGTTOU" - | "SIGURG" - | "SIGUSR1" - | "SIGUSR2" - | "SIGVTALRM" - | "SIGWINCH" - | "SIGXCPU" - | "SIGXFSZ"; - - /** Registers the given function as a listener of the given signal event. - * - * ```ts - * Deno.addSignalListener( - * "SIGTERM", - * () => { - * console.log("SIGTERM!") - * } - * ); - * ``` - * - * _Note_: On Windows only `"SIGINT"` (CTRL+C) and `"SIGBREAK"` (CTRL+Break) - * are supported. - * - * @category Runtime - */ - export function addSignalListener(signal: Signal, handler: () => void): void; - - /** Removes the given signal listener that has been registered with - * {@linkcode Deno.addSignalListener}. - * - * ```ts - * const listener = () => { - * console.log("SIGTERM!") - * }; - * Deno.addSignalListener("SIGTERM", listener); - * Deno.removeSignalListener("SIGTERM", listener); - * ``` - * - * _Note_: On Windows only `"SIGINT"` (CTRL+C) and `"SIGBREAK"` (CTRL+Break) - * are supported. - * - * @category Runtime - */ - export function removeSignalListener( - signal: Signal, - handler: () => void, - ): void; - - /** Create a child process. - * - * If any stdio options are not set to `"piped"`, accessing the corresponding - * field on the `Command` or its `CommandOutput` will throw a `TypeError`. - * - * If `stdin` is set to `"piped"`, the `stdin` {@linkcode WritableStream} - * needs to be closed manually. - * - * `Command` acts as a builder. Each call to {@linkcode Command.spawn} or - * {@linkcode Command.output} will spawn a new subprocess. - * - * @example Spawn a subprocess and pipe the output to a file - * - * ```ts - * const command = new Deno.Command(Deno.execPath(), { - * args: [ - * "eval", - * "console.log('Hello World')", - * ], - * stdin: "piped", - * stdout: "piped", - * }); - * const child = command.spawn(); - * - * // open a file and pipe the subprocess output to it. - * child.stdout.pipeTo( - * Deno.openSync("output", { write: true, create: true }).writable, - * ); - * - * // manually close stdin - * child.stdin.close(); - * const status = await child.status; - * ``` - * - * @example Spawn a subprocess and collect its output - * - * ```ts - * const command = new Deno.Command(Deno.execPath(), { - * args: [ - * "eval", - * "console.log('hello'); console.error('world')", - * ], - * }); - * const { code, stdout, stderr } = await command.output(); - * console.assert(code === 0); - * console.assert("hello\n" === new TextDecoder().decode(stdout)); - * console.assert("world\n" === new TextDecoder().decode(stderr)); - * ``` - * - * @example Spawn a subprocess and collect its output synchronously - * - * ```ts - * const command = new Deno.Command(Deno.execPath(), { - * args: [ - * "eval", - * "console.log('hello'); console.error('world')", - * ], - * }); - * const { code, stdout, stderr } = command.outputSync(); - * console.assert(code === 0); - * console.assert("hello\n" === new TextDecoder().decode(stdout)); - * console.assert("world\n" === new TextDecoder().decode(stderr)); - * ``` - * - * @tags allow-run - * @category Subprocess - */ - export class Command { - constructor(command: string | URL, options?: CommandOptions); - /** - * Executes the {@linkcode Deno.Command}, waiting for it to finish and - * collecting all of its output. - * - * Will throw an error if `stdin: "piped"` is set. - * - * If options `stdout` or `stderr` are not set to `"piped"`, accessing the - * corresponding field on {@linkcode Deno.CommandOutput} will throw a `TypeError`. - */ - output(): Promise; - /** - * Synchronously executes the {@linkcode Deno.Command}, waiting for it to - * finish and collecting all of its output. - * - * Will throw an error if `stdin: "piped"` is set. - * - * If options `stdout` or `stderr` are not set to `"piped"`, accessing the - * corresponding field on {@linkcode Deno.CommandOutput} will throw a `TypeError`. - */ - outputSync(): CommandOutput; - /** - * Spawns a streamable subprocess, allowing to use the other methods. - */ - spawn(): ChildProcess; - } - - /** - * The interface for handling a child process returned from - * {@linkcode Deno.Command.spawn}. - * - * @category Subprocess - */ - export class ChildProcess implements AsyncDisposable { - get stdin(): WritableStream>; - get stdout(): SubprocessReadableStream; - get stderr(): SubprocessReadableStream; - readonly pid: number; - /** Get the status of the child. */ - readonly status: Promise; - - /** Waits for the child to exit completely, returning all its output and - * status. */ - output(): Promise; - /** Kills the process with given {@linkcode Deno.Signal}. - * - * Defaults to `SIGTERM` if no signal is provided. - * - * @param [signo="SIGTERM"] - */ - kill(signo?: Signal): void; - - /** Ensure that the status of the child process prevents the Deno process - * from exiting. */ - ref(): void; - /** Ensure that the status of the child process does not block the Deno - * process from exiting. */ - unref(): void; - - [Symbol.asyncDispose](): Promise; - } - - /** - * The interface for stdout and stderr streams for child process returned from - * {@linkcode Deno.Command.spawn}. - * - * @category Subprocess - */ - export interface SubprocessReadableStream - extends ReadableStream> { - /** - * Reads the stream to completion. It returns a promise that resolves with - * an `ArrayBuffer`. - */ - arrayBuffer(): Promise; - /** - * Reads the stream to completion. It returns a promise that resolves with - * a `Uint8Array`. - */ - bytes(): Promise>; - /** - * Reads the stream to completion. It returns a promise that resolves with - * the result of parsing the body text as JSON. - */ - json(): Promise; - /** - * Reads the stream to completion. It returns a promise that resolves with - * a `USVString` (text). - */ - text(): Promise; - } - - /** - * Options which can be set when calling {@linkcode Deno.Command}. - * - * @category Subprocess - */ - export interface CommandOptions { - /** Arguments to pass to the process. */ - args?: string[]; - /** - * The working directory of the process. - * - * If not specified, the `cwd` of the parent process is used. - */ - cwd?: string | URL; - /** - * Clear environmental variables from parent process. - * - * Doesn't guarantee that only `env` variables are present, as the OS may - * set environmental variables for processes. - * - * @default {false} - */ - clearEnv?: boolean; - /** Environmental variables to pass to the subprocess. */ - env?: Record; - /** - * Sets the child process’s user ID. This translates to a setuid call in the - * child process. Failure in the set uid call will cause the spawn to fail. - */ - uid?: number; - /** Similar to `uid`, but sets the group ID of the child process. */ - gid?: number; - /** - * An {@linkcode AbortSignal} that allows closing the process using the - * corresponding {@linkcode AbortController} by sending the process a - * SIGTERM signal. - * - * Not supported in {@linkcode Deno.Command.outputSync}. - */ - signal?: AbortSignal; - - /** How `stdin` of the spawned process should be handled. - * - * Defaults to `"inherit"` for `output` & `outputSync`, - * and `"inherit"` for `spawn`. */ - stdin?: "piped" | "inherit" | "null"; - /** How `stdout` of the spawned process should be handled. - * - * Defaults to `"piped"` for `output` & `outputSync`, - * and `"inherit"` for `spawn`. */ - stdout?: "piped" | "inherit" | "null"; - /** How `stderr` of the spawned process should be handled. - * - * Defaults to `"piped"` for `output` & `outputSync`, - * and `"inherit"` for `spawn`. */ - stderr?: "piped" | "inherit" | "null"; - - /** Skips quoting and escaping of the arguments on windows. This option - * is ignored on non-windows platforms. - * - * @default {false} */ - windowsRawArguments?: boolean; - - /** Whether to detach the spawned process from the current process. - * This allows the spawned process to continue running after the current - * process exits. - * - * Note: In order to allow the current process to exit, you need to ensure - * you call `unref()` on the child process. - * - * In addition, the stdio streams – if inherited or piped – may keep the - * current process from exiting until the streams are closed. - * - * @default {false} - */ - detached?: boolean; - } - - /** - * @category Subprocess - */ - export interface CommandStatus { - /** If the child process exits with a 0 status code, `success` will be set - * to `true`, otherwise `false`. */ - success: boolean; - /** The exit code of the child process. */ - code: number; - /** The signal associated with the child process. */ - signal: Signal | null; - } - - /** - * The interface returned from calling {@linkcode Deno.Command.output} or - * {@linkcode Deno.Command.outputSync} which represents the result of spawning the - * child process. - * - * @category Subprocess - */ - export interface CommandOutput extends CommandStatus { - /** The buffered output from the child process' `stdout`. */ - readonly stdout: Uint8Array; - /** The buffered output from the child process' `stderr`. */ - readonly stderr: Uint8Array; - } - - /** Option which can be specified when performing {@linkcode Deno.inspect}. - * - * @category I/O */ - export interface InspectOptions { - /** Stylize output with ANSI colors. - * - * @default {false} */ - colors?: boolean; - /** Try to fit more than one entry of a collection on the same line. - * - * @default {true} */ - compact?: boolean; - /** Traversal depth for nested objects. - * - * @default {4} */ - depth?: number; - /** The maximum length for an inspection to take up a single line. - * - * @default {80} */ - breakLength?: number; - /** Whether or not to escape sequences. - * - * @default {true} */ - escapeSequences?: boolean; - /** The maximum number of iterable entries to print. - * - * @default {100} */ - iterableLimit?: number; - /** Show a Proxy's target and handler. - * - * @default {false} */ - showProxy?: boolean; - /** Sort Object, Set and Map entries by key. - * - * @default {false} */ - sorted?: boolean; - /** Add a trailing comma for multiline collections. - * - * @default {false} */ - trailingComma?: boolean; - /** Evaluate the result of calling getters. - * - * @default {false} */ - getters?: boolean; - /** Show an object's non-enumerable properties. - * - * @default {false} */ - showHidden?: boolean; - /** The maximum length of a string before it is truncated with an - * ellipsis. */ - strAbbreviateSize?: number; - } - - /** Converts the input into a string that has the same format as printed by - * `console.log()`. - * - * ```ts - * const obj = { - * a: 10, - * b: "hello", - * }; - * const objAsString = Deno.inspect(obj); // { a: 10, b: "hello" } - * console.log(obj); // prints same value as objAsString, e.g. { a: 10, b: "hello" } - * ``` - * - * A custom inspect functions can be registered on objects, via the symbol - * `Symbol.for("Deno.customInspect")`, to control and customize the output - * of `inspect()` or when using `console` logging: - * - * ```ts - * class A { - * x = 10; - * y = "hello"; - * [Symbol.for("Deno.customInspect")]() { - * return `x=${this.x}, y=${this.y}`; - * } - * } - * - * const inStringFormat = Deno.inspect(new A()); // "x=10, y=hello" - * console.log(inStringFormat); // prints "x=10, y=hello" - * ``` - * - * A depth can be specified by using the `depth` option: - * - * ```ts - * Deno.inspect({a: {b: {c: {d: 'hello'}}}}, {depth: 2}); // { a: { b: [Object] } } - * ``` - * - * @category I/O - */ - export function inspect(value: unknown, options?: InspectOptions): string; - - /** The name of a privileged feature which needs permission. - * - * @category Permissions - */ - export type PermissionName = - | "run" - | "read" - | "write" - | "net" - | "env" - | "sys" - | "ffi"; - - /** The current status of the permission: - * - * - `"granted"` - the permission has been granted. - * - `"denied"` - the permission has been explicitly denied. - * - `"prompt"` - the permission has not explicitly granted nor denied. - * - * @category Permissions - */ - export type PermissionState = "granted" | "denied" | "prompt"; - - /** The permission descriptor for the `allow-run` and `deny-run` permissions, which controls - * access to what sub-processes can be executed by Deno. The option `command` - * allows scoping the permission to a specific executable. - * - * **Warning, in practice, `allow-run` is effectively the same as `allow-all` - * in the sense that malicious code could execute any arbitrary code on the - * host.** - * - * @category Permissions */ - export interface RunPermissionDescriptor { - name: "run"; - /** An `allow-run` or `deny-run` permission can be scoped to a specific executable, - * which would be relative to the start-up CWD of the Deno CLI. */ - command?: string | URL; - } - - /** The permission descriptor for the `allow-read` and `deny-read` permissions, which controls - * access to reading resources from the local host. The option `path` allows - * scoping the permission to a specific path (and if the path is a directory - * any sub paths). - * - * Permission granted under `allow-read` only allows runtime code to attempt - * to read, the underlying operating system may apply additional permissions. - * - * @category Permissions */ - export interface ReadPermissionDescriptor { - name: "read"; - /** An `allow-read` or `deny-read` permission can be scoped to a specific path (and if - * the path is a directory, any sub paths). */ - path?: string | URL; - } - - /** The permission descriptor for the `allow-write` and `deny-write` permissions, which - * controls access to writing to resources from the local host. The option - * `path` allow scoping the permission to a specific path (and if the path is - * a directory any sub paths). - * - * Permission granted under `allow-write` only allows runtime code to attempt - * to write, the underlying operating system may apply additional permissions. - * - * @category Permissions */ - export interface WritePermissionDescriptor { - name: "write"; - /** An `allow-write` or `deny-write` permission can be scoped to a specific path (and if - * the path is a directory, any sub paths). */ - path?: string | URL; - } - - /** The permission descriptor for the `allow-net` and `deny-net` permissions, which controls - * access to opening network ports and connecting to remote hosts via the - * network. The option `host` allows scoping the permission for outbound - * connection to a specific host and port. - * - * @category Permissions */ - export interface NetPermissionDescriptor { - name: "net"; - /** Optional host string of the form `"[:]"`. Examples: - * - * "github.com" - * "deno.land:8080" - */ - host?: string; - } - - /** The permission descriptor for the `allow-env` and `deny-env` permissions, which controls - * access to being able to read and write to the process environment variables - * as well as access other information about the environment. The option - * `variable` allows scoping the permission to a specific environment - * variable. - * - * @category Permissions */ - export interface EnvPermissionDescriptor { - name: "env"; - /** Optional environment variable name (e.g. `PATH`). */ - variable?: string; - } - - /** The permission descriptor for the `allow-sys` and `deny-sys` permissions, which controls - * access to sensitive host system information, which malicious code might - * attempt to exploit. The option `kind` allows scoping the permission to a - * specific piece of information. - * - * @category Permissions */ - export interface SysPermissionDescriptor { - name: "sys"; - /** The specific information to scope the permission to. */ - kind?: - | "loadavg" - | "hostname" - | "systemMemoryInfo" - | "networkInterfaces" - | "osRelease" - | "osUptime" - | "uid" - | "gid" - | "username" - | "cpus" - | "homedir" - | "statfs" - | "getPriority" - | "setPriority"; - } - - /** The permission descriptor for the `allow-ffi` and `deny-ffi` permissions, which controls - * access to loading _foreign_ code and interfacing with it via the - * [Foreign Function Interface API](https://docs.deno.com/runtime/manual/runtime/ffi_api) - * available in Deno. The option `path` allows scoping the permission to a - * specific path on the host. - * - * @category Permissions */ - export interface FfiPermissionDescriptor { - name: "ffi"; - /** Optional path on the local host to scope the permission to. */ - path?: string | URL; - } - - /** The permission descriptor for the `allow-import` and `deny-import` permissions, which controls - * access to importing from remote hosts via the network. The option `host` allows scoping the - * permission for outbound connection to a specific host and port. - * - * @category Permissions */ - export interface ImportPermissionDescriptor { - name: "import"; - /** Optional host string of the form `"[:]"`. Examples: - * - * "github.com" - * "deno.land:8080" - */ - host?: string; - } - - /** Permission descriptors which define a permission and can be queried, - * requested, or revoked. - * - * View the specifics of the individual descriptors for more information about - * each permission kind. - * - * @category Permissions - */ - export type PermissionDescriptor = - | RunPermissionDescriptor - | ReadPermissionDescriptor - | WritePermissionDescriptor - | NetPermissionDescriptor - | EnvPermissionDescriptor - | SysPermissionDescriptor - | FfiPermissionDescriptor - | ImportPermissionDescriptor; - - /** The interface which defines what event types are supported by - * {@linkcode PermissionStatus} instances. - * - * @category Permissions */ - export interface PermissionStatusEventMap { - change: Event; - } - - /** An {@linkcode EventTarget} returned from the {@linkcode Deno.permissions} - * API which can provide updates to any state changes of the permission. - * - * @category Permissions */ - export class PermissionStatus extends EventTarget { - // deno-lint-ignore no-explicit-any - onchange: ((this: PermissionStatus, ev: Event) => any) | null; - readonly state: PermissionState; - /** - * Describes if permission is only granted partially, eg. an access - * might be granted to "/foo" directory, but denied for "/foo/bar". - * In such case this field will be set to `true` when querying for - * read permissions of "/foo" directory. - */ - readonly partial: boolean; - addEventListener( - type: K, - listener: ( - this: PermissionStatus, - ev: PermissionStatusEventMap[K], - ) => any, - options?: boolean | AddEventListenerOptions, - ): void; - addEventListener( - type: string, - listener: EventListenerOrEventListenerObject, - options?: boolean | AddEventListenerOptions, - ): void; - removeEventListener( - type: K, - listener: ( - this: PermissionStatus, - ev: PermissionStatusEventMap[K], - ) => any, - options?: boolean | EventListenerOptions, - ): void; - removeEventListener( - type: string, - listener: EventListenerOrEventListenerObject, - options?: boolean | EventListenerOptions, - ): void; - } - - /** - * Deno's permission management API. - * - * The class which provides the interface for the {@linkcode Deno.permissions} - * global instance and is based on the web platform - * [Permissions API](https://developer.mozilla.org/en-US/docs/Web/API/Permissions_API), - * though some proposed parts of the API which are useful in a server side - * runtime context were removed or abandoned in the web platform specification - * which is why it was chosen to locate it in the {@linkcode Deno} namespace - * instead. - * - * By default, if the `stdin`/`stdout` is TTY for the Deno CLI (meaning it can - * send and receive text), then the CLI will prompt the user to grant - * permission when an un-granted permission is requested. This behavior can - * be changed by using the `--no-prompt` command at startup. When prompting - * the CLI will request the narrowest permission possible, potentially making - * it annoying to the user. The permissions APIs allow the code author to - * request a wider set of permissions at one time in order to provide a better - * user experience. - * - * @category Permissions */ - export class Permissions { - /** Resolves to the current status of a permission. - * - * Note, if the permission is already granted, `request()` will not prompt - * the user again, therefore `query()` is only necessary if you are going - * to react differently existing permissions without wanting to modify them - * or prompt the user to modify them. - * - * ```ts - * const status = await Deno.permissions.query({ name: "read", path: "/etc" }); - * console.log(status.state); - * ``` - */ - query(desc: PermissionDescriptor): Promise; - - /** Returns the current status of a permission. - * - * Note, if the permission is already granted, `request()` will not prompt - * the user again, therefore `querySync()` is only necessary if you are going - * to react differently existing permissions without wanting to modify them - * or prompt the user to modify them. - * - * ```ts - * const status = Deno.permissions.querySync({ name: "read", path: "/etc" }); - * console.log(status.state); - * ``` - */ - querySync(desc: PermissionDescriptor): PermissionStatus; - - /** Revokes a permission, and resolves to the state of the permission. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * - * const status = await Deno.permissions.revoke({ name: "run" }); - * assert(status.state !== "granted") - * ``` - */ - revoke(desc: PermissionDescriptor): Promise; - - /** Revokes a permission, and returns the state of the permission. - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * - * const status = Deno.permissions.revokeSync({ name: "run" }); - * assert(status.state !== "granted") - * ``` - */ - revokeSync(desc: PermissionDescriptor): PermissionStatus; - - /** Requests the permission, and resolves to the state of the permission. - * - * If the permission is already granted, the user will not be prompted to - * grant the permission again. - * - * ```ts - * const status = await Deno.permissions.request({ name: "env" }); - * if (status.state === "granted") { - * console.log("'env' permission is granted."); - * } else { - * console.log("'env' permission is denied."); - * } - * ``` - */ - request(desc: PermissionDescriptor): Promise; - - /** Requests the permission, and returns the state of the permission. - * - * If the permission is already granted, the user will not be prompted to - * grant the permission again. - * - * ```ts - * const status = Deno.permissions.requestSync({ name: "env" }); - * if (status.state === "granted") { - * console.log("'env' permission is granted."); - * } else { - * console.log("'env' permission is denied."); - * } - * ``` - */ - requestSync(desc: PermissionDescriptor): PermissionStatus; - } - - /** Deno's permission management API. - * - * It is a singleton instance of the {@linkcode Permissions} object and is - * based on the web platform - * [Permissions API](https://developer.mozilla.org/en-US/docs/Web/API/Permissions_API), - * though some proposed parts of the API which are useful in a server side - * runtime context were removed or abandoned in the web platform specification - * which is why it was chosen to locate it in the {@linkcode Deno} namespace - * instead. - * - * By default, if the `stdin`/`stdout` is TTY for the Deno CLI (meaning it can - * send and receive text), then the CLI will prompt the user to grant - * permission when an un-granted permission is requested. This behavior can - * be changed by using the `--no-prompt` command at startup. When prompting - * the CLI will request the narrowest permission possible, potentially making - * it annoying to the user. The permissions APIs allow the code author to - * request a wider set of permissions at one time in order to provide a better - * user experience. - * - * Requesting already granted permissions will not prompt the user and will - * return that the permission was granted. - * - * ### Querying - * - * ```ts - * const status = await Deno.permissions.query({ name: "read", path: "/etc" }); - * console.log(status.state); - * ``` - * - * ```ts - * const status = Deno.permissions.querySync({ name: "read", path: "/etc" }); - * console.log(status.state); - * ``` - * - * ### Revoking - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * - * const status = await Deno.permissions.revoke({ name: "run" }); - * assert(status.state !== "granted") - * ``` - * - * ```ts - * import { assert } from "jsr:@std/assert"; - * - * const status = Deno.permissions.revokeSync({ name: "run" }); - * assert(status.state !== "granted") - * ``` - * - * ### Requesting - * - * ```ts - * const status = await Deno.permissions.request({ name: "env" }); - * if (status.state === "granted") { - * console.log("'env' permission is granted."); - * } else { - * console.log("'env' permission is denied."); - * } - * ``` - * - * ```ts - * const status = Deno.permissions.requestSync({ name: "env" }); - * if (status.state === "granted") { - * console.log("'env' permission is granted."); - * } else { - * console.log("'env' permission is denied."); - * } - * ``` - * - * @category Permissions - */ - export const permissions: Permissions; - - /** Information related to the build of the current Deno runtime. - * - * Users are discouraged from code branching based on this information, as - * assumptions about what is available in what build environment might change - * over time. Developers should specifically sniff out the features they - * intend to use. - * - * The intended use for the information is for logging and debugging purposes. - * - * @category Runtime - */ - export const build: { - /** The [LLVM](https://llvm.org/) target triple, which is the combination - * of `${arch}-${vendor}-${os}` and represent the specific build target that - * the current runtime was built for. */ - target: string; - /** Instruction set architecture that the Deno CLI was built for. */ - arch: "x86_64" | "aarch64"; - /** The operating system that the Deno CLI was built for. `"darwin"` is - * also known as OSX or MacOS. */ - os: - | "darwin" - | "linux" - | "android" - | "windows" - | "freebsd" - | "netbsd" - | "aix" - | "solaris" - | "illumos"; - standalone: boolean; - /** The computer vendor that the Deno CLI was built for. */ - vendor: string; - /** Optional environment flags that were set for this build of Deno CLI. */ - env?: string; - }; - - /** Version information related to the current Deno CLI runtime environment. - * - * Users are discouraged from code branching based on this information, as - * assumptions about what is available in what build environment might change - * over time. Developers should specifically sniff out the features they - * intend to use. - * - * The intended use for the information is for logging and debugging purposes. - * - * @category Runtime - */ - export const version: { - /** Deno CLI's version. For example: `"1.26.0"`. */ - deno: string; - /** The V8 version used by Deno. For example: `"10.7.100.0"`. - * - * V8 is the underlying JavaScript runtime platform that Deno is built on - * top of. */ - v8: string; - /** The TypeScript version used by Deno. For example: `"4.8.3"`. - * - * A version of the TypeScript type checker and language server is built-in - * to the Deno CLI. */ - typescript: string; - }; - - /** Returns the script arguments to the program. - * - * Give the following command line invocation of Deno: - * - * ```sh - * deno eval "console.log(Deno.args)" Sushi Maguro Hamachi - * ``` - * - * Then `Deno.args` will contain: - * - * ```ts - * [ "Sushi", "Maguro", "Hamachi" ] - * ``` - * - * If you are looking for a structured way to parse arguments, there is - * [`parseArgs()`](https://jsr.io/@std/cli/doc/parse-args/~/parseArgs) from - * the Deno Standard Library. - * - * @category Runtime - */ - export const args: string[]; - - /** The URL of the entrypoint module entered from the command-line. It - * requires read permission to the CWD. - * - * Also see {@linkcode ImportMeta} for other related information. - * - * @tags allow-read - * @category Runtime - */ - export const mainModule: string; - - /** Options that can be used with {@linkcode symlink} and - * {@linkcode symlinkSync}. - * - * @category File System */ - export interface SymlinkOptions { - /** Specify the symbolic link type as file, directory or NTFS junction. This - * option only applies to Windows and is ignored on other operating systems. */ - type: "file" | "dir" | "junction"; - } - - /** - * Creates `newpath` as a symbolic link to `oldpath`. - * - * The `options.type` parameter can be set to `"file"`, `"dir"` or `"junction"`. - * This argument is only available on Windows and ignored on other platforms. - * - * ```ts - * await Deno.symlink("old/name", "new/name"); - * ``` - * - * Requires full `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function symlink( - oldpath: string | URL, - newpath: string | URL, - options?: SymlinkOptions, - ): Promise; - - /** - * Creates `newpath` as a symbolic link to `oldpath`. - * - * The `options.type` parameter can be set to `"file"`, `"dir"` or `"junction"`. - * This argument is only available on Windows and ignored on other platforms. - * - * ```ts - * Deno.symlinkSync("old/name", "new/name"); - * ``` - * - * Requires full `allow-read` and `allow-write` permissions. - * - * @tags allow-read, allow-write - * @category File System - */ - export function symlinkSync( - oldpath: string | URL, - newpath: string | URL, - options?: SymlinkOptions, - ): void; - - /** - * Synchronously changes the access (`atime`) and modification (`mtime`) times - * of a file system object referenced by `path`. Given times are either in - * seconds (UNIX epoch time) or as `Date` objects. - * - * ```ts - * Deno.utimeSync("myfile.txt", 1556495550, new Date()); - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function utimeSync( - path: string | URL, - atime: number | Date, - mtime: number | Date, - ): void; - - /** - * Changes the access (`atime`) and modification (`mtime`) times of a file - * system object referenced by `path`. Given times are either in seconds - * (UNIX epoch time) or as `Date` objects. - * - * ```ts - * await Deno.utime("myfile.txt", 1556495550, new Date()); - * ``` - * - * Requires `allow-write` permission. - * - * @tags allow-write - * @category File System - */ - export function utime( - path: string | URL, - atime: number | Date, - mtime: number | Date, - ): Promise; - - /** Retrieve the process umask. If `mask` is provided, sets the process umask. - * This call always returns what the umask was before the call. - * - * ```ts - * console.log(Deno.umask()); // e.g. 18 (0o022) - * const prevUmaskValue = Deno.umask(0o077); // e.g. 18 (0o022) - * console.log(Deno.umask()); // e.g. 63 (0o077) - * ``` - * - * This API is under consideration to determine if permissions are required to - * call it. - * - * *Note*: This API is not implemented on Windows - * - * @category File System - */ - export function umask(mask?: number): number; - - /** The object that is returned from a {@linkcode Deno.upgradeWebSocket} - * request. - * - * @category WebSockets */ - export interface WebSocketUpgrade { - /** The response object that represents the HTTP response to the client, - * which should be used to the {@linkcode RequestEvent} `.respondWith()` for - * the upgrade to be successful. */ - response: Response; - /** The {@linkcode WebSocket} interface to communicate to the client via a - * web socket. */ - socket: WebSocket; - } - - /** Options which can be set when performing a - * {@linkcode Deno.upgradeWebSocket} upgrade of a {@linkcode Request} - * - * @category WebSockets */ - export interface UpgradeWebSocketOptions { - /** Sets the `.protocol` property on the client side web socket to the - * value provided here, which should be one of the strings specified in the - * `protocols` parameter when requesting the web socket. This is intended - * for clients and servers to specify sub-protocols to use to communicate to - * each other. */ - protocol?: string; - /** If the client does not respond to this frame with a - * `pong` within the timeout specified, the connection is deemed - * unhealthy and is closed. The `close` and `error` event will be emitted. - * - * The unit is seconds, with a default of 30. - * Set to `0` to disable timeouts. */ - idleTimeout?: number; - } - - /** - * Upgrade an incoming HTTP request to a WebSocket. - * - * Given a {@linkcode Request}, returns a pair of {@linkcode WebSocket} and - * {@linkcode Response} instances. The original request must be responded to - * with the returned response for the websocket upgrade to be successful. - * - * ```ts - * Deno.serve((req) => { - * if (req.headers.get("upgrade") !== "websocket") { - * return new Response(null, { status: 501 }); - * } - * const { socket, response } = Deno.upgradeWebSocket(req); - * socket.addEventListener("open", () => { - * console.log("a client connected!"); - * }); - * socket.addEventListener("message", (event) => { - * if (event.data === "ping") { - * socket.send("pong"); - * } - * }); - * return response; - * }); - * ``` - * - * If the request body is disturbed (read from) before the upgrade is - * completed, upgrading fails. - * - * This operation does not yet consume the request or open the websocket. This - * only happens once the returned response has been passed to `respondWith()`. - * - * @category WebSockets - */ - export function upgradeWebSocket( - request: Request, - options?: UpgradeWebSocketOptions, - ): WebSocketUpgrade; - - /** Send a signal to process under given `pid`. The value and meaning of the - * `signal` to the process is operating system and process dependant. - * {@linkcode Signal} provides the most common signals. Default signal - * is `"SIGTERM"`. - * - * The term `kill` is adopted from the UNIX-like command line command `kill` - * which also signals processes. - * - * If `pid` is negative, the signal will be sent to the process group - * identified by `pid`. An error will be thrown if a negative `pid` is used on - * Windows. - * - * ```ts - * const command = new Deno.Command("sleep", { args: ["10000"] }); - * const child = command.spawn(); - * - * Deno.kill(child.pid, "SIGINT"); - * ``` - * - * Requires `allow-run` permission. - * - * @tags allow-run - * @category Subprocess - */ - export function kill(pid: number, signo?: Signal): void; - - /** The type of the resource record to resolve via DNS using - * {@linkcode Deno.resolveDns}. - * - * Only the listed types are supported currently. - * - * @category Network - */ - export type RecordType = - | "A" - | "AAAA" - | "ANAME" - | "CAA" - | "CNAME" - | "MX" - | "NAPTR" - | "NS" - | "PTR" - | "SOA" - | "SRV" - | "TXT"; - - /** - * Options which can be set when using {@linkcode Deno.resolveDns}. - * - * @category Network */ - export interface ResolveDnsOptions { - /** The name server to be used for lookups. - * - * If not specified, defaults to the system configuration. For example - * `/etc/resolv.conf` on Unix-like systems. */ - nameServer?: { - /** The IP address of the name server. */ - ipAddr: string; - /** The port number the query will be sent to. - * - * @default {53} */ - port?: number; - }; - /** - * An abort signal to allow cancellation of the DNS resolution operation. - * If the signal becomes aborted the resolveDns operation will be stopped - * and the promise returned will be rejected with an AbortError. - */ - signal?: AbortSignal; - } - - /** If {@linkcode Deno.resolveDns} is called with `"CAA"` record type - * specified, it will resolve with an array of objects with this interface. - * - * @category Network - */ - export interface CaaRecord { - /** If `true`, indicates that the corresponding property tag **must** be - * understood if the semantics of the CAA record are to be correctly - * interpreted by an issuer. - * - * Issuers **must not** issue certificates for a domain if the relevant CAA - * Resource Record set contains unknown property tags that have `critical` - * set. */ - critical: boolean; - /** An string that represents the identifier of the property represented by - * the record. */ - tag: string; - /** The value associated with the tag. */ - value: string; - } - - /** If {@linkcode Deno.resolveDns} is called with `"MX"` record type - * specified, it will return an array of objects with this interface. - * - * @category Network */ - export interface MxRecord { - /** A priority value, which is a relative value compared to the other - * preferences of MX records for the domain. */ - preference: number; - /** The server that mail should be delivered to. */ - exchange: string; - } - - /** If {@linkcode Deno.resolveDns} is called with `"NAPTR"` record type - * specified, it will return an array of objects with this interface. - * - * @category Network */ - export interface NaptrRecord { - order: number; - preference: number; - flags: string; - services: string; - regexp: string; - replacement: string; - } - - /** If {@linkcode Deno.resolveDns} is called with `"SOA"` record type - * specified, it will return an array of objects with this interface. - * - * @category Network */ - export interface SoaRecord { - mname: string; - rname: string; - serial: number; - refresh: number; - retry: number; - expire: number; - minimum: number; - } - - /** If {@linkcode Deno.resolveDns} is called with `"SRV"` record type - * specified, it will return an array of objects with this interface. - * - * @category Network - */ - export interface SrvRecord { - priority: number; - weight: number; - port: number; - target: string; - } - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: "A" | "AAAA" | "ANAME" | "CNAME" | "NS" | "PTR", - options?: ResolveDnsOptions, - ): Promise; - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: "CAA", - options?: ResolveDnsOptions, - ): Promise; - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: "MX", - options?: ResolveDnsOptions, - ): Promise; - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: "NAPTR", - options?: ResolveDnsOptions, - ): Promise; - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: "SOA", - options?: ResolveDnsOptions, - ): Promise; - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: "SRV", - options?: ResolveDnsOptions, - ): Promise; - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: "TXT", - options?: ResolveDnsOptions, - ): Promise; - - /** - * Performs DNS resolution against the given query, returning resolved - * records. - * - * Fails in the cases such as: - * - * - the query is in invalid format. - * - the options have an invalid parameter. For example `nameServer.port` is - * beyond the range of 16-bit unsigned integer. - * - the request timed out. - * - * ```ts - * const a = await Deno.resolveDns("example.com", "A"); - * - * const aaaa = await Deno.resolveDns("example.com", "AAAA", { - * nameServer: { ipAddr: "8.8.8.8", port: 53 }, - * }); - * ``` - * - * Requires `allow-net` permission. - * - * @tags allow-net - * @category Network - */ - export function resolveDns( - query: string, - recordType: RecordType, - options?: ResolveDnsOptions, - ): Promise< - | string[] - | CaaRecord[] - | MxRecord[] - | NaptrRecord[] - | SoaRecord[] - | SrvRecord[] - | string[][] - >; - - /** - * Make the timer of the given `id` block the event loop from finishing. - * - * @category Runtime - */ - export function refTimer(id: number): void; - - /** - * Make the timer of the given `id` not block the event loop from finishing. - * - * @category Runtime - */ - export function unrefTimer(id: number): void; - - /** - * Returns the user id of the process on POSIX platforms. Returns null on Windows. - * - * ```ts - * console.log(Deno.uid()); - * ``` - * - * Requires `allow-sys` permission. - * - * @tags allow-sys - * @category Runtime - */ - export function uid(): number | null; - - /** - * Returns the group id of the process on POSIX platforms. Returns null on windows. - * - * ```ts - * console.log(Deno.gid()); - * ``` - * - * Requires `allow-sys` permission. - * - * @tags allow-sys - * @category Runtime - */ - export function gid(): number | null; - - /** Additional information for an HTTP request and its connection. - * - * @category HTTP Server - */ - export interface ServeHandlerInfo { - /** The remote address of the connection. */ - remoteAddr: Addr; - /** The completion promise */ - completed: Promise; - } - - /** A handler for HTTP requests. Consumes a request and returns a response. - * - * If a handler throws, the server calling the handler will assume the impact - * of the error is isolated to the individual request. It will catch the error - * and if necessary will close the underlying connection. - * - * @category HTTP Server - */ - export type ServeHandler = ( - request: Request, - info: ServeHandlerInfo, - ) => Response | Promise; - - /** Interface that module run with `deno serve` subcommand must conform to. - * - * To ensure your code is type-checked properly, make sure to add `satisfies Deno.ServeDefaultExport` - * to the `export default { ... }` like so: - * - * ```ts - * export default { - * fetch(req) { - * return new Response("Hello world"); - * } - * } satisfies Deno.ServeDefaultExport; - * ``` - * - * @category HTTP Server - */ - export interface ServeDefaultExport { - /** A handler for HTTP requests. Consumes a request and returns a response. - * - * If a handler throws, the server calling the handler will assume the impact - * of the error is isolated to the individual request. It will catch the error - * and if necessary will close the underlying connection. - * - * @category HTTP Server - */ - fetch: ServeHandler; - /** - * The callback which is called when the server starts listening. - * - * @category HTTP Server - */ - onListen?: (localAddr: Deno.Addr) => void; - } - - /** Options which can be set when calling {@linkcode Deno.serve}. - * - * @category HTTP Server - */ - export interface ServeOptions { - /** An {@linkcode AbortSignal} to close the server and all connections. */ - signal?: AbortSignal; - - /** The handler to invoke when route handlers throw an error. */ - onError?: (error: unknown) => Response | Promise; - - /** The callback which is called when the server starts listening. */ - onListen?: (localAddr: Addr) => void; - } - - /** - * Options that can be passed to `Deno.serve` to create a server listening on - * a TCP port. - * - * @category HTTP Server - */ - export interface ServeTcpOptions extends ServeOptions { - /** The transport to use. */ - transport?: "tcp"; - - /** The port to listen on. - * - * Set to `0` to listen on any available port. - * - * @default {8000} */ - port?: number; - - /** A literal IP address or host name that can be resolved to an IP address. - * - * __Note about `0.0.0.0`__ While listening `0.0.0.0` works on all platforms, - * the browsers on Windows don't work with the address `0.0.0.0`. - * You should show the message like `server running on localhost:8080` instead of - * `server running on 0.0.0.0:8080` if your program supports Windows. - * - * @default {"0.0.0.0"} */ - hostname?: string; - - /** Sets `SO_REUSEPORT` on POSIX systems. */ - reusePort?: boolean; - - /** Maximum number of pending connections in the listen queue. - * - * This parameter controls how many incoming connections can be queued by the - * operating system while waiting for the application to accept them. If more - * connections arrive when the queue is full, they will be refused. - * - * The kernel may adjust this value (e.g., rounding up to the next power of 2 - * plus 1). Different operating systems have different maximum limits. - * - * @default {511} */ - tcpBacklog?: number; - } - - /** - * Options that can be passed to `Deno.serve` to create a server listening on - * a Unix domain socket. - * - * @category HTTP Server - */ - export interface ServeUnixOptions extends ServeOptions { - /** The transport to use. */ - transport?: "unix"; - - /** The unix domain socket path to listen on. */ - path: string; - } - - /** - * Options that can be passed to `Deno.serve` to create a server listening on - * a VSOCK socket. - * - * @experimental **UNSTABLE**: New API, yet to be vetted. - * - * @category HTTP Server - */ - export interface ServeVsockOptions extends ServeOptions { - /** The transport to use. */ - transport?: "vsock"; - - /** The context identifier to use. */ - cid: number; - - /** The port to use. */ - port: number; - } - - /** - * @category HTTP Server - */ - export interface ServeInit { - /** The handler to invoke to process each incoming request. */ - handler: ServeHandler; - } - - /** An instance of the server created using `Deno.serve()` API. - * - * @category HTTP Server - */ - export interface HttpServer - extends AsyncDisposable { - /** A promise that resolves once server finishes - eg. when aborted using - * the signal passed to {@linkcode ServeOptions.signal}. - */ - finished: Promise; - - /** The local address this server is listening on. */ - addr: Addr; - - /** - * Make the server block the event loop from finishing. - * - * Note: the server blocks the event loop from finishing by default. - * This method is only meaningful after `.unref()` is called. - */ - ref(): void; - - /** Make the server not block the event loop from finishing. */ - unref(): void; - - /** Gracefully close the server. No more new connections will be accepted, - * while pending requests will be allowed to finish. - */ - shutdown(): Promise; - } - - /** Serves HTTP requests with the given handler. - * - * The below example serves with the port `8000` on hostname `"127.0.0.1"`. - * - * ```ts - * Deno.serve((_req) => new Response("Hello, world")); - * ``` - * - * @category HTTP Server - */ - export function serve( - handler: ServeHandler, - ): HttpServer; - /** Serves HTTP requests with the given option bag and handler. - * - * You can specify the socket path with `path` option. - * - * ```ts - * Deno.serve( - * { path: "path/to/socket" }, - * (_req) => new Response("Hello, world") - * ); - * ``` - * - * You can stop the server with an {@linkcode AbortSignal}. The abort signal - * needs to be passed as the `signal` option in the options bag. The server - * aborts when the abort signal is aborted. To wait for the server to close, - * await the promise returned from the `Deno.serve` API. - * - * ```ts - * const ac = new AbortController(); - * - * const server = Deno.serve( - * { signal: ac.signal, path: "path/to/socket" }, - * (_req) => new Response("Hello, world") - * ); - * server.finished.then(() => console.log("Server closed")); - * - * console.log("Closing server..."); - * ac.abort(); - * ``` - * - * By default `Deno.serve` prints the message - * `Listening on path/to/socket` on listening. If you like to - * change this behavior, you can specify a custom `onListen` callback. - * - * ```ts - * Deno.serve({ - * onListen({ path }) { - * console.log(`Server started at ${path}`); - * // ... more info specific to your server .. - * }, - * path: "path/to/socket", - * }, (_req) => new Response("Hello, world")); - * ``` - * - * @category HTTP Server - */ - export function serve( - options: ServeUnixOptions, - handler: ServeHandler, - ): HttpServer; - /** Serves HTTP requests with the given option bag and handler. - * - * @experimental **UNSTABLE**: New API, yet to be vetted. - * - * You can specify an object with the cid and port options for the VSOCK interface. - * - * The VSOCK address family facilitates communication between virtual machines and the host they are running on: https://man7.org/linux/man-pages/man7/vsock.7.html - * - * ```ts - * Deno.serve( - * { cid: -1, port: 3000 }, - * (_req) => new Response("Hello, world") - * ); - * ``` - * - * You can stop the server with an {@linkcode AbortSignal}. The abort signal - * needs to be passed as the `signal` option in the options bag. The server - * aborts when the abort signal is aborted. To wait for the server to close, - * await the promise returned from the `Deno.serve` API. - * - * ```ts - * const ac = new AbortController(); - * - * const server = Deno.serve( - * { signal: ac.signal, cid: -1, port: 3000 }, - * (_req) => new Response("Hello, world") - * ); - * server.finished.then(() => console.log("Server closed")); - * - * console.log("Closing server..."); - * ac.abort(); - * ``` - * - * By default `Deno.serve` prints the message `Listening on cid:port`. - * If you want to change this behavior, you can specify a custom `onListen` - * callback. - * - * ```ts - * Deno.serve({ - * onListen({ cid, port }) { - * console.log(`Server started at ${cid}:${port}`); - * // ... more info specific to your server .. - * }, - * cid: -1, - * port: 3000, - * }, (_req) => new Response("Hello, world")); - * ``` - * - * @category HTTP Server - */ - export function serve( - options: ServeVsockOptions, - handler: ServeHandler, - ): HttpServer; - /** Serves HTTP requests with the given option bag and handler. - * - * You can specify an object with a port and hostname option, which is the - * address to listen on. The default is port `8000` on hostname `"0.0.0.0"`. - * - * You can change the address to listen on using the `hostname` and `port` - * options. The below example serves on port `3000` and hostname `"127.0.0.1"`. - * - * ```ts - * Deno.serve( - * { port: 3000, hostname: "127.0.0.1" }, - * (_req) => new Response("Hello, world") - * ); - * ``` - * - * You can stop the server with an {@linkcode AbortSignal}. The abort signal - * needs to be passed as the `signal` option in the options bag. The server - * aborts when the abort signal is aborted. To wait for the server to close, - * await the promise returned from the `Deno.serve` API. - * - * ```ts - * const ac = new AbortController(); - * - * const server = Deno.serve( - * { signal: ac.signal }, - * (_req) => new Response("Hello, world") - * ); - * server.finished.then(() => console.log("Server closed")); - * - * console.log("Closing server..."); - * ac.abort(); - * ``` - * - * By default `Deno.serve` prints the message - * `Listening on http://:/` on listening. If you like to - * change this behavior, you can specify a custom `onListen` callback. - * - * ```ts - * Deno.serve({ - * onListen({ port, hostname }) { - * console.log(`Server started at http://${hostname}:${port}`); - * // ... more info specific to your server .. - * }, - * }, (_req) => new Response("Hello, world")); - * ``` - * - * To enable TLS you must specify the `key` and `cert` options. - * - * ```ts - * const cert = "-----BEGIN CERTIFICATE-----\n...\n-----END CERTIFICATE-----\n"; - * const key = "-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----\n"; - * Deno.serve({ cert, key }, (_req) => new Response("Hello, world")); - * ``` - * - * @category HTTP Server - */ - export function serve( - options: ServeTcpOptions | (ServeTcpOptions & TlsCertifiedKeyPem), - handler: ServeHandler, - ): HttpServer; - /** Serves HTTP requests with the given option bag. - * - * You can specify an object with the path option, which is the - * unix domain socket to listen on. - * - * ```ts - * const ac = new AbortController(); - * - * const server = Deno.serve({ - * path: "path/to/socket", - * handler: (_req) => new Response("Hello, world"), - * signal: ac.signal, - * onListen({ path }) { - * console.log(`Server started at ${path}`); - * }, - * }); - * server.finished.then(() => console.log("Server closed")); - * - * console.log("Closing server..."); - * ac.abort(); - * ``` - * - * @category HTTP Server - */ - export function serve( - options: ServeUnixOptions & ServeInit, - ): HttpServer; - /** Serves HTTP requests with the given option bag. - * - * The VSOCK address family facilitates communication between virtual machines and the host they are running on: https://man7.org/linux/man-pages/man7/vsock.7.html - * - * @experimental **UNSTABLE**: New API, yet to be vetted. - * - * You can specify an object with the cid and port options for the VSOCK interface. - * - * ```ts - * const ac = new AbortController(); - * - * const server = Deno.serve({ - * cid: -1, - * port: 3000, - * handler: (_req) => new Response("Hello, world"), - * signal: ac.signal, - * onListen({ cid, port }) { - * console.log(`Server started at ${cid}:${port}`); - * }, - * }); - * server.finished.then(() => console.log("Server closed")); - * - * console.log("Closing server..."); - * ac.abort(); - * ``` - * - * @category HTTP Server - */ - export function serve( - options: ServeVsockOptions & ServeInit, - ): HttpServer; - /** Serves HTTP requests with the given option bag. - * - * You can specify an object with a port and hostname option, which is the - * address to listen on. The default is port `8000` on hostname `"0.0.0.0"`. - * - * ```ts - * const ac = new AbortController(); - * - * const server = Deno.serve({ - * port: 3000, - * hostname: "127.0.0.1", - * handler: (_req) => new Response("Hello, world"), - * signal: ac.signal, - * onListen({ port, hostname }) { - * console.log(`Server started at http://${hostname}:${port}`); - * }, - * }); - * server.finished.then(() => console.log("Server closed")); - * - * console.log("Closing server..."); - * ac.abort(); - * ``` - * - * @category HTTP Server - */ - export function serve( - options: - & (ServeTcpOptions | (ServeTcpOptions & TlsCertifiedKeyPem)) - & ServeInit, - ): HttpServer; - - /** All plain number types for interfacing with foreign functions. - * - * @category FFI - */ - export type NativeNumberType = - | "u8" - | "i8" - | "u16" - | "i16" - | "u32" - | "i32" - | "f32" - | "f64"; - - /** All BigInt number types for interfacing with foreign functions. - * - * @category FFI - */ - export type NativeBigIntType = "u64" | "i64" | "usize" | "isize"; - - /** The native boolean type for interfacing to foreign functions. - * - * @category FFI - */ - export type NativeBooleanType = "bool"; - - /** The native pointer type for interfacing to foreign functions. - * - * @category FFI - */ - export type NativePointerType = "pointer"; - - /** The native buffer type for interfacing to foreign functions. - * - * @category FFI - */ - export type NativeBufferType = "buffer"; - - /** The native function type for interfacing with foreign functions. - * - * @category FFI - */ - export type NativeFunctionType = "function"; - - /** The native void type for interfacing with foreign functions. - * - * @category FFI - */ - export type NativeVoidType = "void"; - - /** The native struct type for interfacing with foreign functions. - * - * @category FFI - */ - export interface NativeStructType { - readonly struct: readonly NativeType[]; - } - - /** - * @category FFI - */ - const brand: unique symbol; - - /** - * @category FFI - */ - export type NativeU8Enum = "u8" & { [brand]: T }; - /** - * @category FFI - */ - export type NativeI8Enum = "i8" & { [brand]: T }; - /** - * @category FFI - */ - export type NativeU16Enum = "u16" & { [brand]: T }; - /** - * @category FFI - */ - export type NativeI16Enum = "i16" & { [brand]: T }; - /** - * @category FFI - */ - export type NativeU32Enum = "u32" & { [brand]: T }; - /** - * @category FFI - */ - export type NativeI32Enum = "i32" & { [brand]: T }; - /** - * @category FFI - */ - export type NativeTypedPointer = "pointer" & { - [brand]: T; - }; - /** - * @category FFI - */ - export type NativeTypedFunction = - & "function" - & { - [brand]: T; - }; - - /** All supported types for interfacing with foreign functions. - * - * @category FFI - */ - export type NativeType = - | NativeNumberType - | NativeBigIntType - | NativeBooleanType - | NativePointerType - | NativeBufferType - | NativeFunctionType - | NativeStructType; - - /** @category FFI - */ - export type NativeResultType = NativeType | NativeVoidType; - - /** Type conversion for foreign symbol parameters and unsafe callback return - * types. - * - * @category FFI - */ - export type ToNativeType = T extends - NativeStructType ? BufferSource - : T extends NativeNumberType ? T extends NativeU8Enum ? U - : T extends NativeI8Enum ? U - : T extends NativeU16Enum ? U - : T extends NativeI16Enum ? U - : T extends NativeU32Enum ? U - : T extends NativeI32Enum ? U - : number - : T extends NativeBigIntType ? bigint - : T extends NativeBooleanType ? boolean - : T extends NativePointerType - ? T extends NativeTypedPointer ? U | null - : PointerValue - : T extends NativeFunctionType - ? T extends NativeTypedFunction ? PointerValue | null - : PointerValue - : T extends NativeBufferType ? BufferSource | null - : never; - - /** Type conversion for unsafe callback return types. - * - * @category FFI - */ - export type ToNativeResultType< - T extends NativeResultType = NativeResultType, - > = T extends NativeStructType ? BufferSource - : T extends NativeNumberType ? T extends NativeU8Enum ? U - : T extends NativeI8Enum ? U - : T extends NativeU16Enum ? U - : T extends NativeI16Enum ? U - : T extends NativeU32Enum ? U - : T extends NativeI32Enum ? U - : number - : T extends NativeBigIntType ? bigint - : T extends NativeBooleanType ? boolean - : T extends NativePointerType - ? T extends NativeTypedPointer ? U | null - : PointerValue - : T extends NativeFunctionType - ? T extends NativeTypedFunction ? PointerObject | null - : PointerValue - : T extends NativeBufferType ? BufferSource | null - : T extends NativeVoidType ? void - : never; - - /** A utility type for conversion of parameter types of foreign functions. - * - * @category FFI - */ - export type ToNativeParameterTypes = - // - [T[number][]] extends [T] ? ToNativeType[] - : [readonly T[number][]] extends [T] ? readonly ToNativeType[] - : T extends readonly [...NativeType[]] ? { - [K in keyof T]: ToNativeType; - } - : never; - - /** Type conversion for foreign symbol return types and unsafe callback - * parameters. - * - * @category FFI - */ - export type FromNativeType = T extends - NativeStructType ? Uint8Array - : T extends NativeNumberType ? T extends NativeU8Enum ? U - : T extends NativeI8Enum ? U - : T extends NativeU16Enum ? U - : T extends NativeI16Enum ? U - : T extends NativeU32Enum ? U - : T extends NativeI32Enum ? U - : number - : T extends NativeBigIntType ? bigint - : T extends NativeBooleanType ? boolean - : T extends NativePointerType - ? T extends NativeTypedPointer ? U | null - : PointerValue - : T extends NativeBufferType ? PointerValue - : T extends NativeFunctionType - ? T extends NativeTypedFunction ? PointerObject | null - : PointerValue - : never; - - /** Type conversion for foreign symbol return types. - * - * @category FFI - */ - export type FromNativeResultType< - T extends NativeResultType = NativeResultType, - > = T extends NativeStructType ? Uint8Array - : T extends NativeNumberType ? T extends NativeU8Enum ? U - : T extends NativeI8Enum ? U - : T extends NativeU16Enum ? U - : T extends NativeI16Enum ? U - : T extends NativeU32Enum ? U - : T extends NativeI32Enum ? U - : number - : T extends NativeBigIntType ? bigint - : T extends NativeBooleanType ? boolean - : T extends NativePointerType - ? T extends NativeTypedPointer ? U | null - : PointerValue - : T extends NativeBufferType ? PointerValue - : T extends NativeFunctionType - ? T extends NativeTypedFunction ? PointerObject | null - : PointerValue - : T extends NativeVoidType ? void - : never; - - /** @category FFI - */ - export type FromNativeParameterTypes = - // - [T[number][]] extends [T] ? FromNativeType[] - : [readonly T[number][]] extends [T] - ? readonly FromNativeType[] - : T extends readonly [...NativeType[]] ? { - [K in keyof T]: FromNativeType; - } - : never; - - /** The interface for a foreign function as defined by its parameter and result - * types. - * - * @category FFI - */ - export interface ForeignFunction< - Parameters extends readonly NativeType[] = readonly NativeType[], - Result extends NativeResultType = NativeResultType, - NonBlocking extends boolean = boolean, - > { - /** Name of the symbol. - * - * Defaults to the key name in symbols object. */ - name?: string; - /** The parameters of the foreign function. */ - parameters: Parameters; - /** The result (return value) of the foreign function. */ - result: Result; - /** When `true`, function calls will run on a dedicated blocking thread and - * will return a `Promise` resolving to the `result`. */ - nonblocking?: NonBlocking; - /** When `true`, dlopen will not fail if the symbol is not found. - * Instead, the symbol will be set to `null`. - * - * @default {false} */ - optional?: boolean; - } - - /** @category FFI - */ - export interface ForeignStatic { - /** Name of the symbol, defaults to the key name in symbols object. */ - name?: string; - /** The type of the foreign static value. */ - type: Type; - /** When `true`, dlopen will not fail if the symbol is not found. - * Instead, the symbol will be set to `null`. - * - * @default {false} */ - optional?: boolean; - } - - /** A foreign library interface descriptor. - * - * @category FFI - */ - export interface ForeignLibraryInterface { - [name: string]: ForeignFunction | ForeignStatic; - } - - /** A utility type that infers a foreign symbol. - * - * @category FFI - */ - export type StaticForeignSymbol = - T extends ForeignFunction ? FromForeignFunction - : T extends ForeignStatic ? FromNativeType - : never; - - /** @category FFI - */ - export type FromForeignFunction = - T["parameters"] extends readonly [] ? () => StaticForeignSymbolReturnType - : ( - ...args: ToNativeParameterTypes - ) => StaticForeignSymbolReturnType; - - /** @category FFI - */ - export type StaticForeignSymbolReturnType = - ConditionalAsync>; - - /** @category FFI - */ - export type ConditionalAsync< - IsAsync extends boolean | undefined, - T, - > = IsAsync extends true ? Promise : T; - - /** A utility type that infers a foreign library interface. - * - * @category FFI - */ - export type StaticForeignLibraryInterface = - { - [K in keyof T]: T[K]["optional"] extends true - ? StaticForeignSymbol | null - : StaticForeignSymbol; - }; - - /** A non-null pointer, represented as an object - * at runtime. The object's prototype is `null` - * and cannot be changed. The object cannot be - * assigned to either and is thus entirely read-only. - * - * To interact with memory through a pointer use the - * {@linkcode UnsafePointerView} class. To create a - * pointer from an address or the get the address of - * a pointer use the static methods of the - * {@linkcode UnsafePointer} class. - * - * @category FFI - */ - export interface PointerObject { - [brand]: T; - } - - /** Pointers are represented either with a {@linkcode PointerObject} - * object or a `null` if the pointer is null. - * - * @category FFI - */ - export type PointerValue = null | PointerObject; - - /** A collection of static functions for interacting with pointer objects. - * - * @category FFI - */ - export class UnsafePointer { - /** Create a pointer from a numeric value. This one is really dangerous! */ - static create(value: bigint): PointerValue; - /** Returns `true` if the two pointers point to the same address. */ - static equals(a: PointerValue, b: PointerValue): boolean; - /** Return the direct memory pointer to the typed array in memory. */ - static of( - value: Deno.UnsafeCallback | BufferSource, - ): PointerValue; - /** Return a new pointer offset from the original by `offset` bytes. */ - static offset( - value: PointerObject, - offset: number, - ): PointerValue; - /** Get the numeric value of a pointer */ - static value(value: PointerValue): bigint; - } - - /** An unsafe pointer view to a memory location as specified by the `pointer` - * value. The `UnsafePointerView` API follows the standard built in interface - * {@linkcode DataView} for accessing the underlying types at an memory - * location (numbers, strings and raw bytes). - * - * @category FFI - */ - export class UnsafePointerView { - constructor(pointer: PointerObject); - - pointer: PointerObject; - - /** Gets a boolean at the specified byte offset from the pointer. */ - getBool(offset?: number): boolean; - /** Gets an unsigned 8-bit integer at the specified byte offset from the - * pointer. */ - getUint8(offset?: number): number; - /** Gets a signed 8-bit integer at the specified byte offset from the - * pointer. */ - getInt8(offset?: number): number; - /** Gets an unsigned 16-bit integer at the specified byte offset from the - * pointer. */ - getUint16(offset?: number): number; - /** Gets a signed 16-bit integer at the specified byte offset from the - * pointer. */ - getInt16(offset?: number): number; - /** Gets an unsigned 32-bit integer at the specified byte offset from the - * pointer. */ - getUint32(offset?: number): number; - /** Gets a signed 32-bit integer at the specified byte offset from the - * pointer. */ - getInt32(offset?: number): number; - /** Gets an unsigned 64-bit integer at the specified byte offset from the - * pointer. */ - getBigUint64(offset?: number): bigint; - /** Gets a signed 64-bit integer at the specified byte offset from the - * pointer. */ - getBigInt64(offset?: number): bigint; - /** Gets a signed 32-bit float at the specified byte offset from the - * pointer. */ - getFloat32(offset?: number): number; - /** Gets a signed 64-bit float at the specified byte offset from the - * pointer. */ - getFloat64(offset?: number): number; - /** Gets a pointer at the specified byte offset from the pointer */ - getPointer(offset?: number): PointerValue; - /** Gets a C string (`null` terminated string) at the specified byte offset - * from the pointer. */ - getCString(offset?: number): string; - /** Gets a C string (`null` terminated string) at the specified byte offset - * from the specified pointer. */ - static getCString(pointer: PointerObject, offset?: number): string; - /** Gets an `ArrayBuffer` of length `byteLength` at the specified byte - * offset from the pointer. */ - getArrayBuffer(byteLength: number, offset?: number): ArrayBuffer; - /** Gets an `ArrayBuffer` of length `byteLength` at the specified byte - * offset from the specified pointer. */ - static getArrayBuffer( - pointer: PointerObject, - byteLength: number, - offset?: number, - ): ArrayBuffer; - /** Copies the memory of the pointer into a typed array. - * - * Length is determined from the typed array's `byteLength`. - * - * Also takes optional byte offset from the pointer. */ - copyInto(destination: BufferSource, offset?: number): void; - /** Copies the memory of the specified pointer into a typed array. - * - * Length is determined from the typed array's `byteLength`. - * - * Also takes optional byte offset from the pointer. */ - static copyInto( - pointer: PointerObject, - destination: BufferSource, - offset?: number, - ): void; - } - - /** An unsafe pointer to a function, for calling functions that are not present - * as symbols. - * - * @category FFI - */ - export class UnsafeFnPointer { - /** The pointer to the function. */ - pointer: PointerObject; - /** The definition of the function. */ - definition: Fn; - - constructor( - pointer: PointerObject>>, - definition: Fn, - ); - - /** Call the foreign function. */ - call: FromForeignFunction; - } - - /** Definition of a unsafe callback function. - * - * @category FFI - */ - export interface UnsafeCallbackDefinition< - Parameters extends readonly NativeType[] = readonly NativeType[], - Result extends NativeResultType = NativeResultType, - > { - /** The parameters of the callbacks. */ - parameters: Parameters; - /** The current result of the callback. */ - result: Result; - } - - /** An unsafe callback function. - * - * @category FFI - */ - export type UnsafeCallbackFunction< - Parameters extends readonly NativeType[] = readonly NativeType[], - Result extends NativeResultType = NativeResultType, - > = Parameters extends readonly [] ? () => ToNativeResultType - : ( - ...args: FromNativeParameterTypes - ) => ToNativeResultType; - - /** An unsafe function pointer for passing JavaScript functions as C function - * pointers to foreign function calls. - * - * The function pointer remains valid until the `close()` method is called. - * - * All `UnsafeCallback` are always thread safe in that they can be called from - * foreign threads without crashing. However, they do not wake up the Deno event - * loop by default. - * - * If a callback is to be called from foreign threads, use the `threadSafe()` - * static constructor or explicitly call `ref()` to have the callback wake up - * the Deno event loop when called from foreign threads. This also stops - * Deno's process from exiting while the callback still exists and is not - * unref'ed. - * - * Use `deref()` to then allow Deno's process to exit. Calling `deref()` on - * a ref'ed callback does not stop it from waking up the Deno event loop when - * called from foreign threads. - * - * @category FFI - */ - export class UnsafeCallback< - const Definition extends UnsafeCallbackDefinition = - UnsafeCallbackDefinition, - > { - constructor( - definition: Definition, - callback: UnsafeCallbackFunction< - Definition["parameters"], - Definition["result"] - >, - ); - - /** The pointer to the unsafe callback. */ - readonly pointer: PointerObject; - /** The definition of the unsafe callback. */ - readonly definition: Definition; - /** The callback function. */ - readonly callback: UnsafeCallbackFunction< - Definition["parameters"], - Definition["result"] - >; - - /** - * Creates an {@linkcode UnsafeCallback} and calls `ref()` once to allow it to - * wake up the Deno event loop when called from foreign threads. - * - * This also stops Deno's process from exiting while the callback still - * exists and is not unref'ed. - */ - static threadSafe< - Definition extends UnsafeCallbackDefinition = UnsafeCallbackDefinition, - >( - definition: Definition, - callback: UnsafeCallbackFunction< - Definition["parameters"], - Definition["result"] - >, - ): UnsafeCallback; - - /** - * Increments the callback's reference counting and returns the new - * reference count. - * - * After `ref()` has been called, the callback always wakes up the - * Deno event loop when called from foreign threads. - * - * If the callback's reference count is non-zero, it keeps Deno's - * process from exiting. - */ - ref(): number; - - /** - * Decrements the callback's reference counting and returns the new - * reference count. - * - * Calling `unref()` does not stop a callback from waking up the Deno - * event loop when called from foreign threads. - * - * If the callback's reference counter is zero, it no longer keeps - * Deno's process from exiting. - */ - unref(): number; - - /** - * Removes the C function pointer associated with this instance. - * - * Continuing to use the instance or the C function pointer after closing - * the `UnsafeCallback` will lead to errors and crashes. - * - * Calling this method sets the callback's reference counting to zero, - * stops the callback from waking up the Deno event loop when called from - * foreign threads and no longer keeps Deno's process from exiting. - */ - close(): void; - } - - /** A dynamic library resource. Use {@linkcode Deno.dlopen} to load a dynamic - * library and return this interface. - * - * @category FFI - */ - export interface DynamicLibrary { - /** All of the registered library along with functions for calling them. */ - symbols: StaticForeignLibraryInterface; - /** Removes the pointers associated with the library symbols. - * - * Continuing to use symbols that are part of the library will lead to - * errors and crashes. - * - * Calling this method will also immediately set any references to zero and - * will no longer keep Deno's process from exiting. - */ - close(): void; - } - - /** Opens an external dynamic library and registers symbols, making foreign - * functions available to be called. - * - * Requires `allow-ffi` permission. Loading foreign dynamic libraries can in - * theory bypass all of the sandbox permissions. While it is a separate - * permission users should acknowledge in practice that is effectively the - * same as running with the `allow-all` permission. - * - * @example Given a C library which exports a foreign function named `add()` - * - * ```ts - * // Determine library extension based on - * // your OS. - * let libSuffix = ""; - * switch (Deno.build.os) { - * case "windows": - * libSuffix = "dll"; - * break; - * case "darwin": - * libSuffix = "dylib"; - * break; - * default: - * libSuffix = "so"; - * break; - * } - * - * const libName = `./libadd.${libSuffix}`; - * // Open library and define exported symbols - * const dylib = Deno.dlopen( - * libName, - * { - * "add": { parameters: ["isize", "isize"], result: "isize" }, - * } as const, - * ); - * - * // Call the symbol `add` - * const result = dylib.symbols.add(35n, 34n); // 69n - * - * console.log(`Result from external addition of 35 and 34: ${result}`); - * ``` - * - * @tags allow-ffi - * @category FFI - */ - export function dlopen( - filename: string | URL, - symbols: S, - ): DynamicLibrary; - - /** - * A custom `HttpClient` for use with {@linkcode fetch} function. This is - * designed to allow custom certificates or proxies to be used with `fetch()`. - * - * @example ```ts - * const caCert = await Deno.readTextFile("./ca.pem"); - * const client = Deno.createHttpClient({ caCerts: [ caCert ] }); - * const req = await fetch("https://myserver.com", { client }); - * ``` - * - * @category Fetch - */ - export class HttpClient implements Disposable { - /** Close the HTTP client. */ - close(): void; - - [Symbol.dispose](): void; - } - - /** - * The options used when creating a {@linkcode Deno.HttpClient}. - * - * @category Fetch - */ - export interface CreateHttpClientOptions { - /** A list of root certificates that will be used in addition to the - * default root certificates to verify the peer's certificate. - * - * Must be in PEM format. */ - caCerts?: string[]; - /** An alternative transport (a proxy) to use for new connections. */ - proxy?: Proxy; - /** Sets the maximum number of idle connections per host allowed in the pool. */ - poolMaxIdlePerHost?: number; - /** Set an optional timeout for idle sockets being kept-alive. - * Set to false to disable the timeout. */ - poolIdleTimeout?: number | false; - /** - * Whether HTTP/1.1 is allowed or not. - * - * @default {true} - */ - http1?: boolean; - /** Whether HTTP/2 is allowed or not. - * - * @default {true} - */ - http2?: boolean; - /** Whether setting the host header is allowed or not. - * - * @default {false} - */ - allowHost?: boolean; - /** Sets the local address where the socket will connect from. */ - localAddress?: string; - } - - /** - * The definition for alternative transports (or proxies) in - * {@linkcode Deno.CreateHttpClientOptions}. - * - * Supported proxies: - * - HTTP/HTTPS proxy: this uses passthrough to tunnel HTTP requests, or HTTP - * CONNECT to tunnel HTTPS requests through a different server. - * - SOCKS5 proxy: this uses the SOCKS5 protocol to tunnel TCP connections - * through a different server. - * - TCP socket: this sends all requests to a specified TCP socket. - * - Unix domain socket: this sends all requests to a local Unix domain - * socket rather than a TCP socket. *Not supported on Windows.* - * - Vsock socket: this sends all requests to a local vsock socket. - * *Only supported on Linux and macOS.* - * - * @category Fetch - */ - export type Proxy = { - transport?: "http" | "https" | "socks5"; - /** - * The string URL of the proxy server to use. - * - * For `http` and `https` transports, the URL must start with `http://` or - * `https://` respectively, or be a plain hostname. - * - * For `socks` transport, the URL must start with `socks5://` or - * `socks5h://`. - */ - url: string; - /** The basic auth credentials to be used against the proxy server. */ - basicAuth?: BasicAuth; - } | { - transport: "tcp"; - /** The hostname of the TCP server to connect to. */ - hostname: string; - /** The port of the TCP server to connect to. */ - port: number; - } | { - transport: "unix"; - /** The path to the unix domain socket to use. */ - path: string; - } | { - transport: "vsock"; - /** The CID (Context Identifier) of the vsock to connect to. */ - cid: number; - /** The port of the vsock to connect to. */ - port: number; - }; - - /** - * Basic authentication credentials to be used with a {@linkcode Deno.Proxy} - * server when specifying {@linkcode Deno.CreateHttpClientOptions}. - * - * @category Fetch - */ - export interface BasicAuth { - /** The username to be used against the proxy server. */ - username: string; - /** The password to be used against the proxy server. */ - password: string; - } - - /** Create a custom HttpClient to use with {@linkcode fetch}. This is an - * extension of the web platform Fetch API which allows Deno to use custom - * TLS CA certificates and connect via a proxy while using `fetch()`. - * - * The `cert` and `key` options can be used to specify a client certificate - * and key to use when connecting to a server that requires client - * authentication (mutual TLS or mTLS). The `cert` and `key` options must be - * provided in PEM format. - * - * @example ```ts - * const caCert = await Deno.readTextFile("./ca.pem"); - * const client = Deno.createHttpClient({ caCerts: [ caCert ] }); - * const response = await fetch("https://myserver.com", { client }); - * ``` - * - * @example ```ts - * const client = Deno.createHttpClient({ - * proxy: { url: "http://myproxy.com:8080" } - * }); - * const response = await fetch("https://myserver.com", { client }); - * ``` - * - * @example ```ts - * const key = "----BEGIN PRIVATE KEY----..."; - * const cert = "----BEGIN CERTIFICATE----..."; - * const client = Deno.createHttpClient({ key, cert }); - * const response = await fetch("https://myserver.com", { client }); - * ``` - * - * @category Fetch - */ - export function createHttpClient( - options: - | CreateHttpClientOptions - | (CreateHttpClientOptions & TlsCertifiedKeyPem), - ): HttpClient; - - /** - * APIs for working with the OpenTelemetry observability framework. Deno can - * export traces, metrics, and logs to OpenTelemetry compatible backends via - * the OTLP protocol. - * - * Deno automatically instruments the runtime with OpenTelemetry traces and - * metrics. This data is exported via OTLP to OpenTelemetry compatible - * backends. User logs from the `console` API are exported as OpenTelemetry - * logs via OTLP. - * - * User code can also create custom traces, metrics, and logs using the - * OpenTelemetry API. This is done using the official OpenTelemetry package - * for JavaScript: - * [`npm:@opentelemetry/api`](https://opentelemetry.io/docs/languages/js/). - * Deno integrates with this package to provide tracing, metrics, and trace - * context propagation between native Deno APIs (like `Deno.serve` or `fetch`) - * and custom user code. Deno automatically registers the providers with the - * OpenTelemetry API, so users can start creating custom traces, metrics, and - * logs without any additional setup. - * - * @example Using OpenTelemetry API to create custom traces - * ```ts,ignore - * import { trace } from "npm:@opentelemetry/api@1"; - * - * const tracer = trace.getTracer("example-tracer"); - * - * async function doWork() { - * return tracer.startActiveSpan("doWork", async (span) => { - * span.setAttribute("key", "value"); - * await new Promise((resolve) => setTimeout(resolve, 1000)); - * span.end(); - * }); - * } - * - * Deno.serve(async (req) => { - * await doWork(); - * const resp = await fetch("https://example.com"); - * return resp; - * }); - * ``` - * - * @category Telemetry - */ - export namespace telemetry { - /** - * A TracerProvider compatible with OpenTelemetry.js - * https://open-telemetry.github.io/opentelemetry-js/interfaces/_opentelemetry_api.TracerProvider.html - * - * This is a singleton object that implements the OpenTelemetry - * TracerProvider interface. - * - * @category Telemetry - */ - // deno-lint-ignore no-explicit-any - export const tracerProvider: any; - - /** - * A ContextManager compatible with OpenTelemetry.js - * https://open-telemetry.github.io/opentelemetry-js/interfaces/_opentelemetry_api.ContextManager.html - * - * This is a singleton object that implements the OpenTelemetry - * ContextManager interface. - * - * @category Telemetry - */ - // deno-lint-ignore no-explicit-any - export const contextManager: any; - - /** - * A MeterProvider compatible with OpenTelemetry.js - * https://open-telemetry.github.io/opentelemetry-js/interfaces/_opentelemetry_api.MeterProvider.html - * - * This is a singleton object that implements the OpenTelemetry - * MeterProvider interface. - * - * @category Telemetry - */ - // deno-lint-ignore no-explicit-any - export const meterProvider: any; - - export {}; // only export exports - } - - export {}; // only export exports -} - -// Copyright 2018-2025 the Deno authors. MIT license. - -// deno-lint-ignore-file no-explicit-any - -/// -/// - -/** - * The Console interface provides methods for logging information to the console, - * as well as other utility methods for debugging and inspecting code. - * Methods include logging, debugging, and timing functionality. - * @see https://developer.mozilla.org/en-US/docs/Web/API/console - * - * @category I/O - */ - -interface Console { - /** - * Tests that an expression is true. If not, logs an error message - * @param condition The expression to test for truthiness - * @param data Additional arguments to be printed if the assertion fails - * @example - * ```ts - * console.assert(1 === 1, "This won't show"); - * console.assert(1 === 2, "This will show an error"); - * ``` - */ - assert(condition?: boolean, ...data: any[]): void; - - /** - * Clears the console if the environment allows it - * @example - * ```ts - * console.clear(); - * ``` - */ - clear(): void; - - /** - * Maintains an internal counter for a given label, incrementing it each time the method is called - * @param label The label to count. Defaults to 'default' - * @example - * ```ts - * console.count('myCounter'); - * console.count('myCounter'); // Will show: myCounter: 2 - * ``` - */ - count(label?: string): void; - - /** - * Resets the counter for a given label - * @param label The label to reset. Defaults to 'default' - * @example - * ```ts - * console.count('myCounter'); - * console.countReset('myCounter'); // Resets to 0 - * ``` - */ - countReset(label?: string): void; - - /** - * Outputs a debugging message to the console - * @param data Values to be printed to the console - * @example - * ```ts - * console.debug('Debug message', { detail: 'some data' }); - * ``` - */ - debug(...data: any[]): void; - - /** - * Displays a list of the properties of a specified object - * @param item Object to display - * @param options Formatting options - * @example - * ```ts - * console.dir({ name: 'object', value: 42 }, { depth: 1 }); - * ``` - */ - dir(item?: any, options?: any): void; - - /** - * @ignore - */ - dirxml(...data: any[]): void; - - /** - * Outputs an error message to the console. - * This method routes the output to stderr, - * unlike other console methods that route to stdout. - * @param data Values to be printed to the console - * @example - * ```ts - * console.error('Error occurred:', new Error('Something went wrong')); - * ``` - */ - error(...data: any[]): void; - - /** - * Creates a new inline group in the console, indenting subsequent console messages - * @param data Labels for the group - * @example - * ```ts - * console.group('Group 1'); - * console.log('Inside group 1'); - * console.groupEnd(); - * ``` - */ - group(...data: any[]): void; - - /** - * Creates a new inline group in the console that is initially collapsed - * @param data Labels for the group - * @example - * ```ts - * console.groupCollapsed('Details'); - * console.log('Hidden until expanded'); - * console.groupEnd(); - * ``` - */ - groupCollapsed(...data: any[]): void; - - /** - * Exits the current inline group in the console - * @example - * ```ts - * console.group('Group'); - * console.log('Grouped message'); - * console.groupEnd(); - * ``` - */ - groupEnd(): void; - - /** - * Outputs an informational message to the console - * @param data Values to be printed to the console - * @example - * ```ts - * console.info('Application started', { version: '1.0.0' }); - * ``` - */ - info(...data: any[]): void; - - /** - * Outputs a message to the console - * @param data Values to be printed to the console - * @example - * ```ts - * console.log('Hello', 'World', 123); - * ``` - */ - log(...data: any[]): void; - - /** - * Displays tabular data as a table - * @param tabularData Data to be displayed in table format - * @param properties Array of property names to be displayed - * @example - * ```ts - * console.table([ - * { name: 'John', age: 30 }, - * { name: 'Jane', age: 25 } - * ]); - * ``` - */ - table(tabularData?: any, properties?: string[]): void; - - /** - * Starts a timer you can use to track how long an operation takes - * @param label Timer label. Defaults to 'default' - * @example - * ```ts - * console.time('operation'); - * // ... some code - * console.timeEnd('operation'); - * ``` - */ - time(label?: string): void; - - /** - * Stops a timer that was previously started - * @param label Timer label to stop. Defaults to 'default' - * @example - * ```ts - * console.time('operation'); - * // ... some code - * console.timeEnd('operation'); // Prints: operation: 1234ms - * ``` - */ - timeEnd(label?: string): void; - - /** - * Logs the current value of a timer that was previously started - * @param label Timer label - * @param data Additional data to log - * @example - * ```ts - * console.time('process'); - * // ... some code - * console.timeLog('process', 'Checkpoint A'); - * ``` - */ - timeLog(label?: string, ...data: any[]): void; - - /** - * Outputs a stack trace to the console - * @param data Values to be printed to the console - * @example - * ```ts - * console.trace('Trace message'); - * ``` - */ - trace(...data: any[]): void; - - /** - * Outputs a warning message to the console - * @param data Values to be printed to the console - * @example - * ```ts - * console.warn('Deprecated feature used'); - * ``` - */ - warn(...data: any[]): void; - - /** - * Adds a marker to the DevTools Performance panel - * @param label Label for the timestamp - * @example - * ```ts - * console.timeStamp('Navigation Start'); - * ``` - */ - timeStamp(label?: string): void; - - /** - * Starts recording a performance profile - * @param label Profile label - * @example - * ```ts - * console.profile('Performance Profile'); - * // ... code to profile - * console.profileEnd('Performance Profile'); - * ``` - */ - profile(label?: string): void; - - /** - * Stops recording a performance profile - * @param label Profile label to stop - * @example - * ```ts - * console.profile('Performance Profile'); - * // ... code to profile - * console.profileEnd('Performance Profile'); - * ``` - */ - profileEnd(label?: string): void; -} - -// Copyright 2018-2025 the Deno authors. MIT license. - -// deno-lint-ignore-file no-explicit-any no-var - -/// -/// - -/** - * Iterator for the URLSearchParams class, used to iterate over key-value pairs in search parameters. - * - * @example - * ```ts - * const url = new URL('https://example.org/path?a=1&b=2'); - * const queryString = url.search.substring(1); // Remove the leading '?' - * const params = new URLSearchParams(queryString); - * const iterator = params.entries(); - * console.log(iterator.next().value); // ['a', '1'] - * console.log(iterator.next().value); // ['b', '2'] - * ``` - * - * @category URL - */ -interface URLSearchParamsIterator - extends IteratorObject { - [Symbol.iterator](): URLSearchParamsIterator; -} - -/** - * URLSearchParams provides methods for working with the query string of a URL. - * - * Use this interface to: - * - Parse query parameters from URLs - * - Build and modify query strings - * - Handle form data (when used with FormData) - * - Safely encode/decode URL parameter values - * - * @category URL - */ -interface URLSearchParams { - /** Appends a specified key/value pair as a new search parameter. - * - * ```ts - * let searchParams = new URLSearchParams(); - * searchParams.append('name', 'first'); - * searchParams.append('name', 'second'); - * ``` - */ - append(name: string, value: string): void; - - /** Deletes search parameters that match a name, and optional value, - * from the list of all search parameters. - * - * ```ts - * let searchParams = new URLSearchParams([['name', 'value']]); - * searchParams.delete('name'); - * searchParams.delete('name', 'value'); - * ``` - */ - delete(name: string, value?: string): void; - - /** Returns all the values associated with a given search parameter - * as an array. - * - * ```ts - * searchParams.getAll('name'); - * ``` - */ - getAll(name: string): string[]; - - /** Returns the first value associated to the given search parameter. - * - * ```ts - * searchParams.get('name'); - * ``` - */ - get(name: string): string | null; - - /** Returns a boolean value indicating if a given parameter, - * or parameter and value pair, exists. - * - * ```ts - * searchParams.has('name'); - * searchParams.has('name', 'value'); - * ``` - */ - has(name: string, value?: string): boolean; - - /** Sets the value associated with a given search parameter to the - * given value. If there were several matching values, this method - * deletes the others. If the search parameter doesn't exist, this - * method creates it. - * - * ```ts - * searchParams.set('name', 'value'); - * ``` - */ - set(name: string, value: string): void; - - /** Sort all key/value pairs contained in this object in place and - * return undefined. The sort order is according to Unicode code - * points of the keys. - * - * ```ts - * searchParams.sort(); - * ``` - */ - sort(): void; - - /** Calls a function for each element contained in this object in - * place and return undefined. Optionally accepts an object to use - * as this when executing callback as second argument. - * - * ```ts - * const params = new URLSearchParams([["a", "b"], ["c", "d"]]); - * params.forEach((value, key, parent) => { - * console.log(value, key, parent); - * }); - * ``` - */ - forEach( - callbackfn: (value: string, key: string, parent: this) => void, - thisArg?: any, - ): void; - - /** Returns an iterator allowing to go through all keys contained - * in this object. - * - * ```ts - * const params = new URLSearchParams([["a", "b"], ["c", "d"]]); - * for (const key of params.keys()) { - * console.log(key); - * } - * ``` - */ - keys(): URLSearchParamsIterator; - - /** Returns an iterator allowing to go through all values contained - * in this object. - * - * ```ts - * const params = new URLSearchParams([["a", "b"], ["c", "d"]]); - * for (const value of params.values()) { - * console.log(value); - * } - * ``` - */ - values(): URLSearchParamsIterator; - - /** Returns an iterator allowing to go through all key/value - * pairs contained in this object. - * - * ```ts - * const params = new URLSearchParams([["a", "b"], ["c", "d"]]); - * for (const [key, value] of params.entries()) { - * console.log(key, value); - * } - * ``` - */ - entries(): URLSearchParamsIterator<[string, string]>; - - /** Returns an iterator allowing to go through all key/value - * pairs contained in this object. - * - * ```ts - * const params = new URLSearchParams([["a", "b"], ["c", "d"]]); - * for (const [key, value] of params) { - * console.log(key, value); - * } - * ``` - */ - [Symbol.iterator](): URLSearchParamsIterator<[string, string]>; - - /** Returns a query string suitable for use in a URL. - * - * ```ts - * searchParams.toString(); - * ``` - */ - toString(): string; - - /** Contains the number of search parameters - * - * ```ts - * searchParams.size - * ``` - */ - readonly size: number; -} - -/** @category URL */ -declare var URLSearchParams: { - readonly prototype: URLSearchParams; - /** - * Creates a new URLSearchParams object for parsing query strings. - * - * URLSearchParams is Deno's built-in query string parser, providing a standard - * way to parse, manipulate, and stringify URL query parameters. Instead of manually - * parsing query strings with regex or string operations, use this API for robust - * handling of URL query parameters. - * - * @example - * ```ts - * // From a URL object's query string (recommended approach for parsing query strings in URLs) - * const url = new URL('https://example.org/path?foo=bar&baz=qux'); - * const params = url.searchParams; // No need to manually extract the query string - * console.log(params.get('foo')); // Logs "bar" - * - * // Manually parsing a query string from a URL - * const urlString = 'https://example.org/path?foo=bar&baz=qux'; - * const queryString = urlString.split('?')[1]; // Extract query string part - * const params2 = new URLSearchParams(queryString); - * console.log(params2.get('foo')); // Logs "bar" - * - * // Empty search parameters - * const params3 = new URLSearchParams(); - * console.log(params3.toString()); // Logs "" - * - * // From a string - * const params4 = new URLSearchParams("foo=bar&baz=qux"); - * console.log(params4.get("foo")); // Logs "bar" - * - * // From an array of pairs - * const params5 = new URLSearchParams([["foo", "1"], ["bar", "2"]]); - * console.log(params5.toString()); // Logs "foo=1&bar=2" - * - * // From a record object - * const params6 = new URLSearchParams({"foo": "1", "bar": "2"}); - * console.log(params6.toString()); // Logs "foo=1&bar=2" - * ``` - */ - new ( - init?: - | Iterable - | Record - | string - | URLSearchParams, - ): URLSearchParams; -}; - -/** The URL interface represents an object providing static methods used for - * creating, parsing, and manipulating URLs in Deno. - * - * Use the URL API for safely parsing, constructing, normalizing, and encoding URLs. - * This is the preferred way to work with URLs in Deno rather than manual string - * manipulation which can lead to errors and security issues. - * - * @see https://developer.mozilla.org/docs/Web/API/URL - * - * @category URL - */ -interface URL { - /** - * The hash property of the URL interface is a string that starts with a `#` and is followed by the fragment identifier of the URL. - * It returns an empty string if the URL does not contain a fragment identifier. - * - * @example - * ```ts - * const myURL = new URL('https://example.org/foo#bar'); - * console.log(myURL.hash); // Logs "#bar" - * - * const myOtherURL = new URL('https://example.org'); - * console.log(myOtherURL.hash); // Logs "" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/hash - */ - hash: string; - - /** - * The `host` property of the URL interface is a string that includes the {@linkcode URL.hostname} and the {@linkcode URL.port} if one is specified in the URL includes by including a `:` followed by the port number. - * - * @example - * ```ts - * const myURL = new URL('https://example.org/foo'); - * console.log(myURL.host); // Logs "example.org" - * - * const myOtherURL = new URL('https://example.org:8080/foo'); - * console.log(myOtherURL.host); // Logs "example.org:8080" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/host - */ - host: string; - - /** - * The `hostname` property of the URL interface is a string that represents the fully qualified domain name of the URL. - * - * @example - * ```ts - * const myURL = new URL('https://foo.example.org/bar'); - * console.log(myURL.hostname); // Logs "foo.example.org" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/hostname - */ - hostname: string; - - /** - * The `href` property of the URL interface is a string that represents the complete URL. - * - * @example - * ```ts - * const myURL = new URL('https://foo.example.org/bar?baz=qux#quux'); - * console.log(myURL.href); // Logs "https://foo.example.org/bar?baz=qux#quux" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/href - */ - href: string; - - /** - * The `toString()` method of the URL interface returns a string containing the complete URL. - * - * @example - * ```ts - * const myURL = new URL('https://foo.example.org/bar'); - * console.log(myURL.toString()); // Logs "https://foo.example.org/bar" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/toString - */ - toString(): string; - - /** - * The `origin` property of the URL interface is a string that represents the origin of the URL, that is the {@linkcode URL.protocol}, {@linkcode URL.host}, and {@linkcode URL.port}. - * - * @example - * ```ts - * const myURL = new URL('https://foo.example.org/bar'); - * console.log(myURL.origin); // Logs "https://foo.example.org" - * - * const myOtherURL = new URL('https://example.org:8080/foo'); - * console.log(myOtherURL.origin); // Logs "https://example.org:8080" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/origin - */ - readonly origin: string; - - /** - * The `password` property of the URL interface is a string that represents the password specified in the URL. - * - * @example - * ```ts - * const myURL = new URL('https://someone:somepassword@example.org/baz'); - * console.log(myURL.password); // Logs "somepassword" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/password - */ - password: string; - - /** - * The `pathname` property of the URL interface is a string that represents the path of the URL. - * - * @example - * ```ts - * const myURL = new URL('https://example.org/foo/bar'); - * console.log(myURL.pathname); // Logs "/foo/bar" - * - * const myOtherURL = new URL('https://example.org'); - * console.log(myOtherURL.pathname); // Logs "/" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/pathname - */ - pathname: string; - - /** - * The `port` property of the URL interface is a string that represents the port of the URL if an explicit port has been specified in the URL. - * - * @example - * ```ts - * const myURL = new URL('https://example.org:8080/foo'); - * console.log(myURL.port); // Logs "8080" - * - * const myOtherURL = new URL('https://example.org/foo'); - * console.log(myOtherURL.port); // Logs "" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/port - */ - port: string; - - /** - * The `protocol` property of the URL interface is a string that represents the protocol scheme of the URL and includes a trailing `:`. - * - * @example - * ```ts - * const myURL = new URL('https://example.org/foo'); - * console.log(myURL.protocol); // Logs "https:" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/protocol - */ - protocol: string; - - /** - * The `search` property of the URL interface is a string that represents the search string, or the query string, of the URL. - * This includes the `?` character and the but excludes identifiers within the represented resource such as the {@linkcode URL.hash}. More granular control can be found using {@linkcode URL.searchParams} property. - * - * @example - * ```ts - * const myURL = new URL('https://example.org/foo?bar=baz'); - * console.log(myURL.search); // Logs "?bar=baz" - * - * const myOtherURL = new URL('https://example.org/foo?bar=baz#quux'); - * console.log(myOtherURL.search); // Logs "?bar=baz" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/search - */ - search: string; - - /** - * The `searchParams` property of the URL interface provides a direct interface to - * query parameters through a {@linkcode URLSearchParams} object. - * - * This property offers a convenient way to: - * - Parse URL query parameters - * - Manipulate query strings - * - Add, modify, or delete URL parameters - * - Work with form data in a URL-encoded format - * - Handle query string encoding/decoding automatically - * - * @example - * ```ts - * // Parse and access query parameters from a URL - * const myURL = new URL('https://example.org/search?term=deno&page=2&sort=desc'); - * const params = myURL.searchParams; - * - * console.log(params.get('term')); // Logs "deno" - * console.log(params.get('page')); // Logs "2" - * - * // Check if a parameter exists - * console.log(params.has('sort')); // Logs true - * - * // Add or modify parameters (automatically updates the URL) - * params.append('filter', 'recent'); - * params.set('page', '3'); - * console.log(myURL.href); // URL is updated with new parameters - * - * // Remove a parameter - * params.delete('sort'); - * - * // Iterate over all parameters - * for (const [key, value] of params) { - * console.log(`${key}: ${value}`); - * } - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/searchParams - */ - readonly searchParams: URLSearchParams; - - /** - * The `username` property of the URL interface is a string that represents the username of the URL. - * - * @example - * ```ts - * const myURL = new URL('https://someone:somepassword@example.org/baz'); - * console.log(myURL.username); // Logs "someone" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/username - */ - username: string; - - /** - * The `toJSON()` method of the URL interface returns a JSON representation of the URL. - * - * @example - * ```ts - * const myURL = new URL('https://example.org/foo'); - * console.log(myURL.toJSON()); // Logs "https://example.org/foo" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/toJSON - */ - toJSON(): string; -} - -/** The URL interface represents an object providing static methods used for - * creating, parsing, and manipulating URLs. - * - * @see https://developer.mozilla.org/docs/Web/API/URL - * - * @category URL - */ -declare var URL: { - readonly prototype: URL; - /** - * Creates a new URL object by parsing the specified URL string with an optional base URL. - * Throws a TypeError If the URL is invalid or if a relative URL is provided without a base. - * - * Use this to parse and validate URLs safely. Use this instead of string - * manipulation to ensure correct URL handling, proper encoding, and protection against - * security issues like path traversal attacks. - * - * @example - * ```ts - * // Creating a URL from an absolute URL string - * const url1 = new URL('https://example.org/foo'); - * console.log(url1.href); // Logs "https://example.org/foo" - * - * // Creating a URL from a relative URL string with a base URL - * const url2 = new URL('/bar', 'https://example.org'); - * console.log(url2.href); // Logs "https://example.org/bar" - * - * // Joining path segments safely (prevents path traversal) - * const baseUrl = 'https://api.example.com/v1'; - * const userInput = '../secrets'; // Potentially malicious input - * const safeUrl = new URL(userInput, baseUrl); - * console.log(safeUrl.href); // Correctly resolves to "https://api.example.com/secrets" - * - * // Constructing URLs with proper encoding - * const search = 'query with spaces'; - * const url3 = new URL('https://example.org/search'); - * url3.searchParams.set('q', search); // Automatically handles URL encoding - * console.log(url3.href); // "https://example.org/search?q=query+with+spaces" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/URL - */ - new (url: string | URL, base?: string | URL): URL; - - /** - * Parses a URL string or URL object and returns a URL object. - * - * @example - * ```ts - * const myURL = URL.parse('https://example.org'); - * console.log(myURL.href); // Logs "https://example.org/" - * console.log(myURL.hostname); // Logs "example.org" - * console.log(myURL.pathname); // Logs "/" - * console.log(myURL.protocol); // Logs "https:" - * - * const baseURL = new URL('https://example.org'); - * const myNewURL = URL.parse('/foo', baseURL); - * console.log(myNewURL.href); // Logs "https://example.org/foo" - * console.log(myNewURL.hostname); // Logs "example.org" - * console.log(myNewURL.pathname); // Logs "/foo" - * console.log(myNewURL.protocol); // Logs "https:" - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/parse_static - */ - parse(url: string | URL, base?: string | URL): URL | null; - - /** - * Returns a boolean value indicating if a URL string is valid and can be parsed. - * - * @example - * ```ts - * // Check if an absolute URL string is valid - * console.log(URL.canParse('https://example.org')); // Logs true - * console.log(URL.canParse('https:://example.org')); // Logs false - * - * // Check if a relative URL string with a base is valid - * console.log(URL.canParse('/foo', 'https://example.org')); // Logs true - * console.log(URL.canParse('/foo', 'https:://example.org')); // Logs false - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/canParse_static - */ - canParse(url: string | URL, base?: string | URL): boolean; - - /** - * Creates a unique, temporary URL that represents a given Blob, File, or MediaSource object. - * - * This method is particularly useful for: - * - Creating URLs for dynamically generated content - * - Working with blobs in a browser context - * - Creating workers from dynamically generated code - * - Setting up temporary URL references for file downloads - * - * Note: Always call URL.revokeObjectURL() when you're done using the URL to prevent memory leaks. - * - * @example - * ```ts - * // Create a URL string for a Blob - * const blob = new Blob(["Hello, world!"], { type: "text/plain" }); - * const url = URL.createObjectURL(blob); - * console.log(url); // Logs something like "blob:null/1234-5678-9101-1121" - * - * // Dynamic web worker creation in Deno - * const workerCode = ` - * self.onmessage = (e) => { - * self.postMessage(e.data.toUpperCase()); - * }; - * `; - * const workerBlob = new Blob([workerCode], { type: "application/javascript" }); - * const workerUrl = URL.createObjectURL(workerBlob); - * const worker = new Worker(workerUrl, { type: "module" }); - * - * worker.onmessage = (e) => console.log(e.data); - * worker.postMessage("hello from deno"); - * - * // Always revoke when done to prevent memory leaks - * URL.revokeObjectURL(workerUrl); - * ``` - * - * @see https://developer.mozilla.org/docs/Web/API/URL/createObjectURL_static - */ - createObjectURL(blob: Blob): string; - - /** - * Revokes a previously created object URL, freeing the memory associated with it. - * - * Important for memory management in applications that create dynamic URLs. - * Once an object URL is revoked: - * - It can no longer be used to fetch the content it referenced - * - The browser/runtime is allowed to release the memory or resources associated with it - * - Workers created via the URL will continue to run, but the URL becomes invalid for new creations - * - * For security and performance in Deno applications, always revoke object URLs as soon as - * they're no longer needed, especially when processing large files or generating many URLs. - * - * @see https://developer.mozilla.org/docs/Web/API/URL/revokeObjectURL_static - */ - revokeObjectURL(url: string): void; -}; - -/** @category URL */ -interface URLPatternInit { - protocol?: string; - username?: string; - password?: string; - hostname?: string; - port?: string; - pathname?: string; - search?: string; - hash?: string; - baseURL?: string; -} - -/** @category URL */ -type URLPatternInput = string | URLPatternInit; - -/** @category URL */ -interface URLPatternComponentResult { - input: string; - groups: Record; -} - -/** `URLPatternResult` is the object returned from `URLPattern.exec`. - * - * @category URL - */ -interface URLPatternResult { - /** The inputs provided when matching. */ - inputs: [URLPatternInit] | [URLPatternInit, string]; - - /** The matched result for the `protocol` matcher. */ - protocol: URLPatternComponentResult; - /** The matched result for the `username` matcher. */ - username: URLPatternComponentResult; - /** The matched result for the `password` matcher. */ - password: URLPatternComponentResult; - /** The matched result for the `hostname` matcher. */ - hostname: URLPatternComponentResult; - /** The matched result for the `port` matcher. */ - port: URLPatternComponentResult; - /** The matched result for the `pathname` matcher. */ - pathname: URLPatternComponentResult; - /** The matched result for the `search` matcher. */ - search: URLPatternComponentResult; - /** The matched result for the `hash` matcher. */ - hash: URLPatternComponentResult; -} - -/** - * Options for the {@linkcode URLPattern} constructor. - * - * @category URL - */ -interface URLPatternOptions { - /** - * Enables case-insensitive matching. - * - * @default {false} - */ - ignoreCase: boolean; -} - -/** - * The URLPattern API provides a web platform primitive for matching URLs based - * on a convenient pattern syntax. - * - * Common use cases for URLPattern include: - * - Building routers for web applications - * - Pattern-matching URLs for middleware - * - Extracting parameters from URL paths - * - URL-based feature toggles - * - Routing in serverless and edge functions - * - * The syntax is based on path-to-regexp, supporting wildcards, named capture groups, - * regular groups, and group modifiers - similar to Express.js route patterns. - * - * @example - * ```ts - * // Basic routing with URLPattern (similar to Express.js) - * const routes = [ - * new URLPattern({ pathname: "/users" }), - * new URLPattern({ pathname: "/users/:id" }), - * new URLPattern({ pathname: "/products/:category/:id?" }), - * ]; - * - * // Check incoming request against routes - * function handleRequest(req: Request) { - * const url = new URL(req.url); - * - * for (const route of routes) { - * const match = route.exec(url); - * if (match) { - * // Extract parameters from the URL - * const params = match.pathname.groups; - * return new Response(`Matched: ${JSON.stringify(params)}`); - * } - * } - * - * return new Response("Not found", { status: 404 }); - * } - * ``` - * - * @example - * ```ts - * // Matching different URL parts - * const apiPattern = new URLPattern({ - * protocol: "https", - * hostname: "api.example.com", - * pathname: "/v:version/:resource/:id?", - * search: "*", // Match any query string - * }); - * - * const match = apiPattern.exec("https://api.example.com/v1/users/123?format=json"); - * if (match) { - * console.log(match.pathname.groups.version); // "1" - * console.log(match.pathname.groups.resource); // "users" - * console.log(match.pathname.groups.id); // "123" - * } - * ``` - * - * @category URL - */ -interface URLPattern { - /** - * Test if the given input matches the stored pattern. - * - * The input can either be provided as an absolute URL string with an optional base, - * relative URL string with a required base, or as individual components - * in the form of an `URLPatternInit` object. - * - * ```ts - * const pattern = new URLPattern("https://example.com/books/:id"); - * - * // Test an absolute url string. - * console.log(pattern.test("https://example.com/books/123")); // true - * - * // Test a relative url with a base. - * console.log(pattern.test("/books/123", "https://example.com")); // true - * - * // Test an object of url components. - * console.log(pattern.test({ pathname: "/books/123" })); // true - * ``` - */ - test(input: URLPatternInput, baseURL?: string): boolean; - - /** - * Match the given input against the stored pattern. - * - * The input can either be provided as an absolute URL string with an optional base, - * relative URL string with a required base, or as individual components - * in the form of an `URLPatternInit` object. - * - * ```ts - * const pattern = new URLPattern("https://example.com/books/:id"); - * - * // Match an absolute url string. - * let match = pattern.exec("https://example.com/books/123"); - * console.log(match.pathname.groups.id); // 123 - * - * // Match a relative url with a base. - * match = pattern.exec("/books/123", "https://example.com"); - * console.log(match.pathname.groups.id); // 123 - * - * // Match an object of url components. - * match = pattern.exec({ pathname: "/books/123" }); - * console.log(match.pathname.groups.id); // 123 - * ``` - */ - exec(input: URLPatternInput, baseURL?: string): URLPatternResult | null; - - /** The pattern string for the `protocol`. */ - readonly protocol: string; - /** The pattern string for the `username`. */ - readonly username: string; - /** The pattern string for the `password`. */ - readonly password: string; - /** The pattern string for the `hostname`. */ - readonly hostname: string; - /** The pattern string for the `port`. */ - readonly port: string; - /** The pattern string for the `pathname`. */ - readonly pathname: string; - /** The pattern string for the `search`. */ - readonly search: string; - /** The pattern string for the `hash`. */ - readonly hash: string; - - /** Whether or not any of the specified groups use regexp groups. */ - readonly hasRegExpGroups: boolean; -} - -/** - * The URLPattern API provides a web platform primitive for matching URLs based - * on a convenient pattern syntax. - * - * The syntax is based on path-to-regexp. Wildcards, named capture groups, - * regular groups, and group modifiers are all supported. - * - * ```ts - * // Specify the pattern as structured data. - * const pattern = new URLPattern({ pathname: "/users/:user" }); - * const match = pattern.exec("https://blog.example.com/users/joe"); - * console.log(match.pathname.groups.user); // joe - * ``` - * - * ```ts - * // Specify a fully qualified string pattern. - * const pattern = new URLPattern("https://example.com/books/:id"); - * console.log(pattern.test("https://example.com/books/123")); // true - * console.log(pattern.test("https://deno.land/books/123")); // false - * ``` - * - * ```ts - * // Specify a relative string pattern with a base URL. - * const pattern = new URLPattern("/article/:id", "https://blog.example.com"); - * console.log(pattern.test("https://blog.example.com/article")); // false - * console.log(pattern.test("https://blog.example.com/article/123")); // true - * ``` - * - * @category URL - */ -declare var URLPattern: { - readonly prototype: URLPattern; - new ( - input: URLPatternInput, - baseURL: string, - options?: URLPatternOptions, - ): URLPattern; - new (input?: URLPatternInput, options?: URLPatternOptions): URLPattern; -}; - -// Copyright 2018-2025 the Deno authors. MIT license. - -// deno-lint-ignore-file no-explicit-any no-var - -/// -/// - -/** @category Platform */ -interface DOMException extends Error { - readonly name: string; - readonly message: string; - /** @deprecated */ - readonly code: number; - readonly INDEX_SIZE_ERR: 1; - readonly DOMSTRING_SIZE_ERR: 2; - readonly HIERARCHY_REQUEST_ERR: 3; - readonly WRONG_DOCUMENT_ERR: 4; - readonly INVALID_CHARACTER_ERR: 5; - readonly NO_DATA_ALLOWED_ERR: 6; - readonly NO_MODIFICATION_ALLOWED_ERR: 7; - readonly NOT_FOUND_ERR: 8; - readonly NOT_SUPPORTED_ERR: 9; - readonly INUSE_ATTRIBUTE_ERR: 10; - readonly INVALID_STATE_ERR: 11; - readonly SYNTAX_ERR: 12; - readonly INVALID_MODIFICATION_ERR: 13; - readonly NAMESPACE_ERR: 14; - readonly INVALID_ACCESS_ERR: 15; - readonly VALIDATION_ERR: 16; - readonly TYPE_MISMATCH_ERR: 17; - readonly SECURITY_ERR: 18; - readonly NETWORK_ERR: 19; - readonly ABORT_ERR: 20; - readonly URL_MISMATCH_ERR: 21; - readonly QUOTA_EXCEEDED_ERR: 22; - readonly TIMEOUT_ERR: 23; - readonly INVALID_NODE_TYPE_ERR: 24; - readonly DATA_CLONE_ERR: 25; -} - -/** @category Platform */ -declare var DOMException: { - readonly prototype: DOMException; - new (message?: string, name?: string): DOMException; - readonly INDEX_SIZE_ERR: 1; - readonly DOMSTRING_SIZE_ERR: 2; - readonly HIERARCHY_REQUEST_ERR: 3; - readonly WRONG_DOCUMENT_ERR: 4; - readonly INVALID_CHARACTER_ERR: 5; - readonly NO_DATA_ALLOWED_ERR: 6; - readonly NO_MODIFICATION_ALLOWED_ERR: 7; - readonly NOT_FOUND_ERR: 8; - readonly NOT_SUPPORTED_ERR: 9; - readonly INUSE_ATTRIBUTE_ERR: 10; - readonly INVALID_STATE_ERR: 11; - readonly SYNTAX_ERR: 12; - readonly INVALID_MODIFICATION_ERR: 13; - readonly NAMESPACE_ERR: 14; - readonly INVALID_ACCESS_ERR: 15; - readonly VALIDATION_ERR: 16; - readonly TYPE_MISMATCH_ERR: 17; - readonly SECURITY_ERR: 18; - readonly NETWORK_ERR: 19; - readonly ABORT_ERR: 20; - readonly URL_MISMATCH_ERR: 21; - readonly QUOTA_EXCEEDED_ERR: 22; - readonly TIMEOUT_ERR: 23; - readonly INVALID_NODE_TYPE_ERR: 24; - readonly DATA_CLONE_ERR: 25; -}; - -/** @category Events */ -interface EventInit { - bubbles?: boolean; - cancelable?: boolean; - composed?: boolean; -} - -/** An event which takes place in the DOM. - * - * @category Events - */ -interface Event { - /** Returns true or false depending on how event was initialized. True if - * event goes through its target's ancestors in reverse tree order, and - * false otherwise. */ - readonly bubbles: boolean; - /** @deprecated */ - cancelBubble: boolean; - /** Returns true or false depending on how event was initialized. Its return - * value does not always carry meaning, but true can indicate that part of the - * operation during which event was dispatched, can be canceled by invoking - * the preventDefault() method. */ - readonly cancelable: boolean; - /** Returns true or false depending on how event was initialized. True if - * event invokes listeners past a ShadowRoot node that is the root of its - * target, and false otherwise. */ - readonly composed: boolean; - /** Returns the object whose event listener's callback is currently being - * invoked. */ - readonly currentTarget: EventTarget | null; - /** Returns true if preventDefault() was invoked successfully to indicate - * cancellation, and false otherwise. */ - readonly defaultPrevented: boolean; - /** Returns the event's phase, which is one of NONE, CAPTURING_PHASE, - * AT_TARGET, and BUBBLING_PHASE. */ - readonly eventPhase: number; - /** Returns true if event was dispatched by the user agent, and false - * otherwise. */ - readonly isTrusted: boolean; - /** @deprecated */ - returnValue: boolean; - /** @deprecated */ - readonly srcElement: EventTarget | null; - /** Returns the object to which event is dispatched (its target). */ - readonly target: EventTarget | null; - /** Returns the event's timestamp as the number of milliseconds measured - * relative to the time origin. */ - readonly timeStamp: number; - /** Returns the type of event, e.g. "click", "hashchange", or "submit". */ - readonly type: string; - /** Returns the invocation target objects of event's path (objects on which - * listeners will be invoked), except for any nodes in shadow trees of which - * the shadow root's mode is "closed" that are not reachable from event's - * currentTarget. */ - composedPath(): EventTarget[]; - /** @deprecated */ - initEvent(type: string, bubbles?: boolean, cancelable?: boolean): void; - /** If invoked when the cancelable attribute value is true, and while - * executing a listener for the event with passive set to false, signals to - * the operation that caused event to be dispatched that it needs to be - * canceled. */ - preventDefault(): void; - /** Invoking this method prevents event from reaching any registered event - * listeners after the current one finishes running and, when dispatched in a - * tree, also prevents event from reaching any other objects. */ - stopImmediatePropagation(): void; - /** When dispatched in a tree, invoking this method prevents event from - * reaching any objects other than the current object. */ - stopPropagation(): void; - readonly NONE: 0; - readonly CAPTURING_PHASE: 1; - readonly AT_TARGET: 2; - readonly BUBBLING_PHASE: 3; -} - -/** An event which takes place in the DOM. - * - * @category Events - */ -declare var Event: { - readonly prototype: Event; - new (type: string, eventInitDict?: EventInit): Event; - readonly NONE: 0; - readonly CAPTURING_PHASE: 1; - readonly AT_TARGET: 2; - readonly BUBBLING_PHASE: 3; -}; - -/** - * EventTarget is a DOM interface implemented by objects that can receive events - * and may have listeners for them. - * - * @category Events - */ -interface EventTarget { - /** Appends an event listener for events whose type attribute value is type. - * The callback argument sets the callback that will be invoked when the event - * is dispatched. - * - * The options argument sets listener-specific options. For compatibility this - * can be a boolean, in which case the method behaves exactly as if the value - * was specified as options's capture. - * - * When set to true, options's capture prevents callback from being invoked - * when the event's eventPhase attribute value is BUBBLING_PHASE. When false - * (or not present), callback will not be invoked when event's eventPhase - * attribute value is CAPTURING_PHASE. Either way, callback will be invoked if - * event's eventPhase attribute value is AT_TARGET. - * - * When set to true, options's passive indicates that the callback will not - * cancel the event by invoking preventDefault(). This is used to enable - * performance optimizations described in § 2.8 Observing event listeners. - * - * When set to true, options's once indicates that the callback will only be - * invoked once after which the event listener will be removed. - * - * The event listener is appended to target's event listener list and is not - * appended if it has the same type, callback, and capture. */ - addEventListener( - type: string, - listener: EventListenerOrEventListenerObject | null, - options?: boolean | AddEventListenerOptions, - ): void; - /** Dispatches a synthetic event to event target and returns true if either - * event's cancelable attribute value is false or its preventDefault() method - * was not invoked, and false otherwise. */ - dispatchEvent(event: Event): boolean; - /** Removes the event listener in target's event listener list with the same - * type, callback, and options. */ - removeEventListener( - type: string, - callback: EventListenerOrEventListenerObject | null, - options?: EventListenerOptions | boolean, - ): void; -} - -/** - * EventTarget is a DOM interface implemented by objects that can receive events - * and may have listeners for them. - * - * @category Events - */ -declare var EventTarget: { - readonly prototype: EventTarget; - new (): EventTarget; -}; - -/** @category Events */ -interface EventListener { - /** - * The `EventListener` interface represents a callback function to be called - * whenever an event of a specific type occurs on a target object. - * - * This is a basic event listener, represented by a simple function - * that receives an Event object as its only parameter. - * - * @example - * ```ts - * // Create an event listener function - * const handleEvent = (event: Event) => { - * console.log(`Event of type "${event.type}" occurred`); - * console.log(`Event phase: ${event.eventPhase}`); - * - * // Access event properties - * if (event.cancelable) { - * event.preventDefault(); - * } - * }; - * - * // Attach the event listener to a target - * const target = new EventTarget(); - * target.addEventListener('custom', handleEvent); - * - * // Or create a listener inline - * target.addEventListener('message', (event) => { - * console.log('Message received:', event); - * }); - * ``` - * - * @category Events - */ - (evt: Event): void; -} - -/** - * The `EventListenerObject` interface represents an object that can handle events - * dispatched by an `EventTarget` object. - * - * This interface provides an alternative to using a function as an event listener. - * When implementing an object with this interface, the `handleEvent()` method - * will be called when the event is triggered. - * - * @example - * ```ts - * // Creating an object that implements `EventListenerObject` - * const myEventListener = { - * handleEvent(event) { - * console.log(`Event of type ${event.type} occurred`); - * - * // You can use 'this' to access other methods or properties - * this.additionalProcessing(event); - * }, - * - * additionalProcessing(event) { - * // Additional event handling logic - * console.log('Additional processing for:', event); - * } - * }; - * - * // Using with any EventTarget (server or client contexts) - * const target = new EventTarget(); - * target.addEventListener('message', myEventListener); - * - * // Later, to remove it: - * target.removeEventListener('message', myEventListener); - * ``` - * - * @category Events - */ -interface EventListenerObject { - handleEvent(evt: Event): void; -} - -/** @category Events */ -type EventListenerOrEventListenerObject = - | EventListener - | EventListenerObject; - -/** - * Options for configuring an event listener via `addEventListener`. - * - * This interface extends `EventListenerOptions` and provides additional configuration - * options to control event listener behavior. - * - * @example - * ```ts - * eventTarget.addEventListener('message', handler, { - * once: true, - * passive: true, - * signal: controller.signal - * }); - * ``` - * - * @category Events */ -interface AddEventListenerOptions extends EventListenerOptions { - /** - * When set to true, the listener will automatically be removed after it has been invoked once. - */ - once?: boolean; - - /** - * When set to true, indicates that the listener will never call `preventDefault()`. - * This provides a performance optimization opportunity for event processing. - * If a passive listener attempts to call `preventDefault()`, the call will be ignored - * and a warning may be generated. - */ - passive?: boolean; - - /** - * An `AbortSignal` that can be used to remove the event listener when aborted. - * - * @example - * ```ts - * const controller = new AbortController(); - * eventTarget.addEventListener('message', handler, { signal: controller.signal }); - * - * // Later, to remove the listener: - * controller.abort(); - * ``` - */ - signal?: AbortSignal; -} - -/** @category Events */ -interface EventListenerOptions { - capture?: boolean; -} - -/** @category Events */ -interface ProgressEventInit extends EventInit { - lengthComputable?: boolean; - loaded?: number; - total?: number; -} - -/** Events measuring progress of an underlying process, like an HTTP request - * (for an XMLHttpRequest, or the loading of the underlying resource of an - * ,