nitro-nightly 3.0.1-20251219-124228-00598a8a → 3.0.1-20251222-100607-0f3740df

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  import { C as isAbsolute$1, O as relative$1, b as basename$1, h as resolveModulePath, k as resolve$1, o as debounce, w as join$1, x as dirname$1 } from "../_libs/c12.mjs";
2
- import { t as assetsPlugin } from "../_libs/@hiogawa/vite-plugin-fullstack.mjs";
2
+ import { n as assetsPlugin } from "../_libs/@hiogawa/vite-plugin-fullstack.mjs";
3
3
  import { t as formatCompatibilityDate } from "../_libs/compatx.mjs";
4
4
  import { i as a, r as T } from "../_libs/std-env.mjs";
5
5
  import { a as copyPublicAssets, i as prepare, s as createNitro } from "../_nitro.mjs";
@@ -3,7 +3,6 @@ import path from "node:path";
3
3
  import fs from "node:fs";
4
4
  import { fileURLToPath } from "node:url";
5
5
  import assert from "node:assert";
6
- import "srvx/node";
7
6
  import { createHash } from "node:crypto";
8
7
  import { isCSSRequest, normalizePath } from "vite";
9
8
  import assert$1 from "node:assert/strict";
@@ -1536,7 +1535,37 @@ function stripLiteral(code, options) {
1536
1535
  }
1537
1536
 
1538
1537
  //#endregion
1539
- //#region node_modules/.pnpm/@hiogawa+vite-plugin-fullstack@0.0.8_patch_hash=aef5693ec569067da78c3402c9b2884429e322a_ccdea5f53e47d0c803c48383e7777859/node_modules/@hiogawa/vite-plugin-fullstack/dist/index.js
1538
+ //#region node_modules/.pnpm/@rolldown+pluginutils@1.0.0-beta.55/node_modules/@rolldown/pluginutils/dist/simple-filters.js
1539
+ /**
1540
+ * Constructs a RegExp that matches the exact string specified.
1541
+ *
1542
+ * This is useful for plugin hook filters.
1543
+ *
1544
+ * @param str the string to match.
1545
+ * @param flags flags for the RegExp.
1546
+ *
1547
+ * @example
1548
+ * ```ts
1549
+ * import { exactRegex } from '@rolldown/pluginutils';
1550
+ * const plugin = {
1551
+ * name: 'plugin',
1552
+ * resolveId: {
1553
+ * filter: { id: exactRegex('foo') },
1554
+ * handler(id) {} // will only be called for `foo`
1555
+ * }
1556
+ * }
1557
+ * ```
1558
+ */
1559
+ function exactRegex(str, flags) {
1560
+ return new RegExp(`^${escapeRegex(str)}$`, flags);
1561
+ }
1562
+ const escapeRegexRE = /[-/\\^$*+?.()|[\]{}]/g;
1563
+ function escapeRegex(str) {
1564
+ return str.replace(escapeRegexRE, "\\$&");
1565
+ }
1566
+
1567
+ //#endregion
1568
+ //#region node_modules/.pnpm/@hiogawa+vite-plugin-fullstack@0.0.11_vite@8.0.0-beta.2_@types+node@25.0.3_jiti@2.6.1_tsx@4.21.0_yaml@2.8.2_/node_modules/@hiogawa/vite-plugin-fullstack/dist/plugin-B4MlD0Bd.js
1540
1569
  function parseIdQuery(id) {
1541
1570
  if (!id.includes("?")) return {
1542
1571
  filename: id,
@@ -1554,23 +1583,20 @@ function toAssetsVirtual(options) {
1554
1583
  function parseAssetsVirtual(id) {
1555
1584
  if (id.startsWith("\0virtual:fullstack/assets?")) return parseIdQuery(id).query;
1556
1585
  }
1557
- function escapeRegExp(string) {
1558
- return string.replace(/[-\\^$*+?.()|[\]{}]/g, String.raw`\$&`);
1559
- }
1560
1586
  function createVirtualPlugin(name, load) {
1561
1587
  name = "virtual:" + name;
1562
1588
  return {
1563
- name: `rsc:virtual-${name}`,
1589
+ name: `fullstack:virtual-${name}`,
1564
1590
  resolveId: {
1565
- filter: { id: /* @__PURE__ */ new RegExp("^" + escapeRegExp(name) + "$") },
1591
+ filter: { id: exactRegex(name) },
1566
1592
  handler(source, _importer, _options) {
1567
1593
  return source === name ? "\0" + name : void 0;
1568
1594
  }
1569
1595
  },
1570
1596
  load: {
1571
- filter: { id: /* @__PURE__ */ new RegExp("^\\0" + escapeRegExp(name) + "$") },
1597
+ filter: { id: exactRegex("\0" + name) },
1572
1598
  handler(id, options) {
1573
- if (id === "\0" + name) return load.apply(this, [id, options]);
1599
+ return load.apply(this, [id, options]);
1574
1600
  }
1575
1601
  }
1576
1602
  };
@@ -1799,33 +1825,7 @@ function assetsPlugin(pluginOpts) {
1799
1825
  load: {
1800
1826
  filter: { id: /^\0virtual:fullstack\// },
1801
1827
  async handler(id) {
1802
- if (id === "\0virtual:fullstack/runtime") return `//#region src/runtime.ts
1803
- function mergeAssets(...args) {
1804
- const js = uniqBy(args.flatMap((h) => h.js), (a) => a.href);
1805
- const css = uniqBy(args.flatMap((h) => h.css), (a) => a.href);
1806
- const entry = args.filter((arg) => arg.entry)?.[0]?.entry;
1807
- const raw = {
1808
- entry,
1809
- js,
1810
- css
1811
- };
1812
- return {
1813
- ...raw,
1814
- merge: (...args$1) => mergeAssets(raw, ...args$1)
1815
- };
1816
- }
1817
- function uniqBy(array, key) {
1818
- const seen = /* @__PURE__ */ new Set();
1819
- return array.filter((item) => {
1820
- const k = key(item);
1821
- if (seen.has(k)) return false;
1822
- seen.add(k);
1823
- return true;
1824
- });
1825
- }
1826
-
1827
- //#endregion
1828
- export { mergeAssets };`;
1828
+ if (id === "\0virtual:fullstack/runtime") return `export const mergeAssets = ${(await import("../../cli/_chunks/runtime.mjs")).mergeAssets.toString()};`;
1829
1829
  const parsed = parseAssetsVirtual(id);
1830
1830
  if (!parsed) return;
1831
1831
  assert$1.notEqual(this.environment.name, "client");
@@ -2051,7 +2051,7 @@ function patchViteClientPlugin() {
2051
2051
  return {
2052
2052
  name: "fullstack:patch-vite-client",
2053
2053
  transform: {
2054
- filter: { id: /* @__PURE__ */ new RegExp("^" + escapeRegExp(viteClientPath) + "$") },
2054
+ filter: { id: exactRegex(viteClientPath) },
2055
2055
  handler(code, id) {
2056
2056
  if (id === viteClientPath) {
2057
2057
  if (code.includes("linkSheetsMap")) return;
@@ -2150,4 +2150,29 @@ function assetsURLDev(url, config) {
2150
2150
  }
2151
2151
 
2152
2152
  //#endregion
2153
- export { encode as a, decode as i, stripLiteral as n, MagicString as r, assetsPlugin as t };
2153
+ //#region node_modules/.pnpm/@hiogawa+vite-plugin-fullstack@0.0.11_vite@8.0.0-beta.2_@types+node@25.0.3_jiti@2.6.1_tsx@4.21.0_yaml@2.8.2_/node_modules/@hiogawa/vite-plugin-fullstack/dist/runtime.js
2154
+ function mergeAssets(...args) {
2155
+ const js = uniqBy(args.flatMap((h) => h.js), (a) => a.href);
2156
+ const css = uniqBy(args.flatMap((h) => h.css), (a) => a.href);
2157
+ const raw = {
2158
+ entry: args.filter((arg) => arg.entry)?.[0]?.entry,
2159
+ js,
2160
+ css
2161
+ };
2162
+ return {
2163
+ ...raw,
2164
+ merge: (...args$1) => mergeAssets(raw, ...args$1)
2165
+ };
2166
+ function uniqBy(array, key) {
2167
+ const seen = /* @__PURE__ */ new Set();
2168
+ return array.filter((item) => {
2169
+ const k = key(item);
2170
+ if (seen.has(k)) return false;
2171
+ seen.add(k);
2172
+ return true;
2173
+ });
2174
+ }
2175
+ }
2176
+
2177
+ //#endregion
2178
+ export { decode as a, MagicString as i, assetsPlugin as n, encode as o, stripLiteral as r, mergeAssets as t };
@@ -1,4 +1,4 @@
1
- import { a as encode, i as decode } from "../@hiogawa/vite-plugin-fullstack.mjs";
1
+ import { a as decode, o as encode } from "../@hiogawa/vite-plugin-fullstack.mjs";
2
2
 
3
3
  //#region node_modules/.pnpm/@jridgewell+resolve-uri@3.1.2/node_modules/@jridgewell/resolve-uri/dist/resolve-uri.mjs
4
4
  const schemeRegex = /^[\w+.-]+:\/\//;
@@ -1,6 +1,6 @@
1
1
  import path from "node:path";
2
2
 
3
- //#region node_modules/.pnpm/@rollup+plugin-alias@6.0.0_rollup@4.53.5/node_modules/@rollup/plugin-alias/dist/index.js
3
+ //#region node_modules/.pnpm/@rollup+plugin-alias@6.0.0_rollup@4.54.0/node_modules/@rollup/plugin-alias/dist/index.js
4
4
  function matches(pattern, importee) {
5
5
  if (pattern instanceof RegExp) return pattern.test(importee);
6
6
  if (importee.length < pattern.length) return false;
@@ -1,5 +1,5 @@
1
1
  import { i as __toESM, n as __require$1, t as __commonJSMin } from "../../_rolldown.mjs";
2
- import { r as MagicString } from "../@hiogawa/vite-plugin-fullstack.mjs";
2
+ import { i as MagicString } from "../@hiogawa/vite-plugin-fullstack.mjs";
3
3
  import * as nativeFs$1 from "fs";
4
4
  import { existsSync, readFileSync, statSync } from "fs";
5
5
  import { basename, dirname, extname, isAbsolute, join, normalize, posix, relative, resolve, sep, win32 } from "path";
@@ -2327,7 +2327,7 @@ function walk(ast, { enter, leave }) {
2327
2327
  }
2328
2328
 
2329
2329
  //#endregion
2330
- //#region node_modules/.pnpm/@rollup+pluginutils@5.3.0_rollup@4.53.5/node_modules/@rollup/pluginutils/dist/es/index.js
2330
+ //#region node_modules/.pnpm/@rollup+pluginutils@5.3.0_rollup@4.54.0/node_modules/@rollup/pluginutils/dist/es/index.js
2331
2331
  var import_picomatch = /* @__PURE__ */ __toESM(require_picomatch(), 1);
2332
2332
  const extractors = {
2333
2333
  ArrayPattern(names, param) {
@@ -2611,7 +2611,7 @@ var require_is_reference = /* @__PURE__ */ __commonJSMin(((exports, module) => {
2611
2611
  }));
2612
2612
 
2613
2613
  //#endregion
2614
- //#region node_modules/.pnpm/@rollup+plugin-commonjs@29.0.0_rollup@4.53.5/node_modules/@rollup/plugin-commonjs/dist/es/index.js
2614
+ //#region node_modules/.pnpm/@rollup+plugin-commonjs@29.0.0_rollup@4.54.0/node_modules/@rollup/plugin-commonjs/dist/es/index.js
2615
2615
  var import_commondir = /* @__PURE__ */ __toESM(require_commondir(), 1);
2616
2616
  var import_is_reference = /* @__PURE__ */ __toESM(require_is_reference(), 1);
2617
2617
  var version = "29.0.0";
@@ -1,8 +1,8 @@
1
- import { r as MagicString } from "../@hiogawa/vite-plugin-fullstack.mjs";
1
+ import { i as MagicString } from "../@hiogawa/vite-plugin-fullstack.mjs";
2
2
  import { a as makeLegalIdentifier, n as attachScopes, o as walk, r as createFilter } from "./plugin-commonjs.mjs";
3
3
  import { sep } from "path";
4
4
 
5
- //#region node_modules/.pnpm/@rollup+plugin-inject@5.0.5_rollup@4.53.5/node_modules/@rollup/plugin-inject/dist/es/index.js
5
+ //#region node_modules/.pnpm/@rollup+plugin-inject@5.0.5_rollup@4.54.0/node_modules/@rollup/plugin-inject/dist/es/index.js
6
6
  var escape = function(str) {
7
7
  return str.replace(/[-[\]/{}()*+?.\\^$|]/g, "\\$&");
8
8
  };
@@ -1,6 +1,6 @@
1
1
  import { i as dataToEsm, r as createFilter } from "./plugin-commonjs.mjs";
2
2
 
3
- //#region node_modules/.pnpm/@rollup+plugin-json@6.1.0_rollup@4.53.5/node_modules/@rollup/plugin-json/dist/es/index.js
3
+ //#region node_modules/.pnpm/@rollup+plugin-json@6.1.0_rollup@4.54.0/node_modules/@rollup/plugin-json/dist/es/index.js
4
4
  function json(options) {
5
5
  if (options === void 0) options = {};
6
6
  var filter = createFilter(options.include, options.exclude);
@@ -1113,7 +1113,7 @@ var require_resolve = /* @__PURE__ */ __commonJSMin(((exports, module) => {
1113
1113
  }));
1114
1114
 
1115
1115
  //#endregion
1116
- //#region node_modules/.pnpm/@rollup+plugin-node-resolve@16.0.3_rollup@4.53.5/node_modules/@rollup/plugin-node-resolve/dist/es/index.js
1116
+ //#region node_modules/.pnpm/@rollup+plugin-node-resolve@16.0.3_rollup@4.54.0/node_modules/@rollup/plugin-node-resolve/dist/es/index.js
1117
1117
  var import_cjs = /* @__PURE__ */ __toESM(require_cjs(), 1);
1118
1118
  var import_is_module = /* @__PURE__ */ __toESM(require_is_module(), 1);
1119
1119
  var import_resolve = /* @__PURE__ */ __toESM(require_resolve(), 1);
@@ -1,7 +1,7 @@
1
- import { r as MagicString } from "../@hiogawa/vite-plugin-fullstack.mjs";
1
+ import { i as MagicString } from "../@hiogawa/vite-plugin-fullstack.mjs";
2
2
  import { r as createFilter } from "./plugin-commonjs.mjs";
3
3
 
4
- //#region node_modules/.pnpm/@rollup+plugin-replace@6.0.3_rollup@4.53.5/node_modules/@rollup/plugin-replace/dist/es/index.js
4
+ //#region node_modules/.pnpm/@rollup+plugin-replace@6.0.3_rollup@4.54.0/node_modules/@rollup/plugin-replace/dist/es/index.js
5
5
  function escape(str) {
6
6
  return str.replace(/[-[\]/{}()*+?.\\^$|]/g, "\\$&");
7
7
  }
@@ -1,6 +1,6 @@
1
1
  import { i as __toESM, n as __require, t as __commonJSMin } from "../_rolldown.mjs";
2
2
  import { C as isAbsolute$2, D as parse$1, O as relative$1, T as normalize$2, b as basename$1, f as readPackageJSON, k as resolve$1, m as resolvePackageJSON, w as join$1, x as dirname$1 } from "./c12.mjs";
3
- import { n as stripLiteral, r as MagicString } from "./@hiogawa/vite-plugin-fullstack.mjs";
3
+ import { i as MagicString, r as stripLiteral } from "./@hiogawa/vite-plugin-fullstack.mjs";
4
4
  import { n as parse$2, t as Parser } from "./acorn.mjs";
5
5
  import { a as findTypeExports, c as parseStaticImport, i as findStaticImports, l as resolve$2, n as detectSyntax, r as findExports, t as resolveModule, u as resolveModuleExportNames } from "./local-pkg.mjs";
6
6
  import { c as require_picomatch } from "./@rollup/plugin-commonjs.mjs";
@@ -1,5 +1,5 @@
1
1
  import { b as basename, h as resolveModulePath } from "./c12.mjs";
2
- import { r as MagicString } from "./@hiogawa/vite-plugin-fullstack.mjs";
2
+ import { i as MagicString } from "./@hiogawa/vite-plugin-fullstack.mjs";
3
3
  import { a as genString, i as genSafeVariableName, n as genObjectFromRaw, t as genImport } from "./knitwork.mjs";
4
4
  import { existsSync, promises } from "node:fs";
5
5
  import { fileURLToPath } from "node:url";
@@ -0,0 +1,3 @@
1
+ import { t as mergeAssets } from "../../_libs/@hiogawa/vite-plugin-fullstack.mjs";
2
+
3
+ export { mergeAssets };
@@ -37,12 +37,12 @@ function callHooks(hooks, args, startIndex, task) {
37
37
  return Promise.reject(error);
38
38
  }
39
39
  }
40
- function serialTaskCaller(hooks, args) {
41
- if (hooks.length > 0) return callHooks(hooks, args, 0, createTask(args.shift()));
40
+ function serialTaskCaller(hooks, args, name) {
41
+ if (hooks.length > 0) return callHooks(hooks, args, 0, createTask(name));
42
42
  }
43
- function parallelTaskCaller(hooks, args) {
43
+ function parallelTaskCaller(hooks, args, name) {
44
44
  if (hooks.length > 0) {
45
- const task = createTask(args.shift());
45
+ const task = createTask(name);
46
46
  return Promise.all(hooks.map((hook) => task.run(() => hook(...args))));
47
47
  }
48
48
  }
@@ -164,8 +164,7 @@ var Hookable = class {
164
164
  context: {}
165
165
  } : void 0;
166
166
  if (this._before) callEachWith(this._before, event);
167
- const _args = args?.length ? [name, ...args] : [name];
168
- const result = caller(this._hooks[name] ? [...this._hooks[name]] : [], _args);
167
+ const result = caller(this._hooks[name] ? [...this._hooks[name]] : [], args, name);
169
168
  if (result instanceof Promise) return result.finally(() => {
170
169
  if (this._after && event) callEachWith(this._after, event);
171
170
  });
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hookable",
3
- "version": "6.0.0",
3
+ "version": "6.0.1",
4
4
  "description": "Awaitable hook system",
5
5
  "keywords": [
6
6
  "hook",
@@ -14,11 +14,7 @@ export const handler = awslambda.streamifyResponse(async (event, responseStream,
14
14
  controller.enqueue("");
15
15
  controller.close();
16
16
  } });
17
- const writer = awslambda.HttpResponseStream.from(
18
- // @ts-expect-error TODO: IMPORTANT! It should be a Writable according to the aws-lambda types
19
- responseStream,
20
- httpResponseMetadata
21
- );
17
+ const writer = awslambda.HttpResponseStream.from(responseStream, httpResponseMetadata);
22
18
  const reader = body.getReader();
23
19
  await streamToNodeStream(reader, responseStream);
24
20
  writer.end();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nitro-nightly",
3
- "version": "3.0.1-20251219-124228-00598a8a",
3
+ "version": "3.0.1-20251222-100607-0f3740df",
4
4
  "description": "Build and Deploy Universal JavaScript Servers",
5
5
  "homepage": "https://nitro.build",
6
6
  "repository": "nitrojs/nitro",
@@ -67,8 +67,8 @@
67
67
  "jiti": "^2.6.1",
68
68
  "ofetch": "^2.0.0-alpha.3",
69
69
  "ohash": "^2.0.11",
70
- "oxc-minify": "^0.103.0",
71
- "oxc-transform": "^0.103.0",
70
+ "oxc-minify": "^0.105.0",
71
+ "oxc-transform": "^0.105.0",
72
72
  "srvx": "^0.9.8",
73
73
  "undici": "^7.16.0",
74
74
  "unenv": "^2.0.0-rc.24",
@@ -77,18 +77,18 @@
77
77
  "devDependencies": {
78
78
  "@azure/functions": "^3.5.1",
79
79
  "@azure/static-web-apps-cli": "^2.0.7",
80
- "@cloudflare/workers-types": "^4.20251217.0",
80
+ "@cloudflare/workers-types": "^4.20251221.0",
81
81
  "@deno/types": "^0.0.1",
82
- "@hiogawa/vite-plugin-fullstack": "^0.0.8",
82
+ "@hiogawa/vite-plugin-fullstack": "^0.0.11",
83
83
  "@netlify/edge-functions": "^3.0.3",
84
- "@netlify/functions": "^5.1.1",
84
+ "@netlify/functions": "^5.1.2",
85
85
  "@rollup/plugin-alias": "^6.0.0",
86
86
  "@rollup/plugin-commonjs": "^29.0.0",
87
87
  "@rollup/plugin-inject": "^5.0.5",
88
88
  "@rollup/plugin-json": "^6.1.0",
89
89
  "@rollup/plugin-node-resolve": "^16.0.3",
90
90
  "@rollup/plugin-replace": "^6.0.3",
91
- "@scalar/api-reference": "^1.40.5",
91
+ "@scalar/api-reference": "^1.40.9",
92
92
  "@types/aws-lambda": "^8.10.159",
93
93
  "@types/estree": "^1.0.8",
94
94
  "@types/etag": "^1.8.4",
@@ -119,16 +119,16 @@
119
119
  "execa": "^9.6.1",
120
120
  "expect-type": "^1.3.0",
121
121
  "exsolve": "^1.0.8",
122
- "fs-extra": "^11.3.2",
122
+ "fs-extra": "^11.3.3",
123
123
  "get-port-please": "^3.2.0",
124
124
  "gzip-size": "^7.0.0",
125
- "hookable": "^6.0.0",
125
+ "hookable": "^6.0.1",
126
126
  "httpxy": "^0.1.7",
127
127
  "klona": "^2.0.6",
128
128
  "knitwork": "^1.3.0",
129
129
  "magic-string": "^0.30.21",
130
130
  "mime": "^4.1.0",
131
- "miniflare": "^4.20251213.0",
131
+ "miniflare": "^4.20251217.0",
132
132
  "mlly": "^1.8.0",
133
133
  "nf3": "^0.3.1",
134
134
  "nypm": "^0.6.2",
@@ -140,8 +140,8 @@
140
140
  "pretty-bytes": "^7.1.0",
141
141
  "react": "^19.2.3",
142
142
  "rendu": "^0.0.7",
143
- "rolldown": "1.0.0-beta.55",
144
- "rollup": "^4.53.5",
143
+ "rolldown": "1.0.0-beta.56",
144
+ "rollup": "^4.54.0",
145
145
  "rou3": "^0.7.12",
146
146
  "scule": "^1.3.0",
147
147
  "semver": "^7.7.3",
@@ -161,7 +161,7 @@
161
161
  "vite": "8.0.0-beta.2",
162
162
  "vite7": "npm:vite@^7.3.0",
163
163
  "vitest": "^4.0.16",
164
- "wrangler": "^4.55.0",
164
+ "wrangler": "^4.56.0",
165
165
  "xml2js": "^0.6.2",
166
166
  "youch": "4.1.0-beta.13",
167
167
  "youch-core": "^0.3.3"