@nuxt/nitro-server-nightly 4.3.2-29531071.e4e4ae81 → 4.3.2-29531289.6a3bd23e
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.
- package/dist/index.mjs +1 -1
- package/dist/runtime/handlers/island.d.mts +3 -2
- package/dist/runtime/handlers/island.mjs +2 -1
- package/dist/runtime/handlers/renderer.d.mts +3 -2
- package/dist/runtime/handlers/renderer.mjs +2 -1
- package/dist/runtime/middleware/no-ssr.d.mts +3 -2
- package/dist/runtime/middleware/no-ssr.mjs +2 -1
- package/dist/runtime/plugins/dev-server-logs.d.mts +2 -1
- package/dist/runtime/utils/cache.d.mts +11 -5
- package/dist/runtime/utils/config.d.mts +1 -1
- package/dist/runtime/utils/error.d.mts +1 -1
- package/dist/runtime/utils/error.mjs +1 -1
- package/dist/runtime/utils/renderer/build-files.d.mts +2 -2
- package/package.json +9 -9
package/dist/index.mjs
CHANGED
|
@@ -19,7 +19,7 @@ import { isWindows } from "std-env";
|
|
|
19
19
|
import { ImpoundPlugin } from "impound";
|
|
20
20
|
import { resolveModulePath } from "exsolve";
|
|
21
21
|
import { runtimeDependencies } from "nitropack/runtime/meta";
|
|
22
|
-
var version = "4.3.2-
|
|
22
|
+
var version = "4.3.2-29531289.6a3bd23e";
|
|
23
23
|
function toArray(value) {
|
|
24
24
|
return Array.isArray(value) ? value : [value];
|
|
25
25
|
}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import type { EventHandler } from "h3";
|
|
2
|
+
declare const handler: EventHandler;
|
|
3
|
+
export default handler;
|
|
@@ -10,7 +10,7 @@ import { getSSRRenderer } from "../utils/renderer/build-files.mjs";
|
|
|
10
10
|
import { renderInlineStyles } from "../utils/renderer/inline-styles.mjs";
|
|
11
11
|
import { getClientIslandResponse, getServerComponentHTML, getSlotIslandResponse } from "../utils/renderer/islands.mjs";
|
|
12
12
|
const ISLAND_SUFFIX_RE = /\.json(?:\?.*)?$/;
|
|
13
|
-
|
|
13
|
+
const handler = defineEventHandler(async (event) => {
|
|
14
14
|
const nitroApp = useNitroApp();
|
|
15
15
|
setResponseHeaders(event, {
|
|
16
16
|
"content-type": "application/json;charset=utf-8",
|
|
@@ -95,6 +95,7 @@ export default defineEventHandler(async (event) => {
|
|
|
95
95
|
}
|
|
96
96
|
return islandResponse;
|
|
97
97
|
});
|
|
98
|
+
export default handler;
|
|
98
99
|
async function getIslandContext(event) {
|
|
99
100
|
// TODO: Strict validation for url
|
|
100
101
|
let url = event.path || "";
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import type { EventHandler } from "h3";
|
|
2
|
+
declare const handler: EventHandler;
|
|
3
|
+
export default handler;
|
|
@@ -38,7 +38,7 @@ const APP_TELEPORT_CLOSE_TAG = HAS_APP_TELEPORTS ? `</${appTeleportTag}>` : "";
|
|
|
38
38
|
const PAYLOAD_URL_RE = NUXT_JSON_PAYLOADS ? /^[^?]*\/_payload.json(?:\?.*)?$/ : /^[^?]*\/_payload.js(?:\?.*)?$/;
|
|
39
39
|
const PAYLOAD_FILENAME = NUXT_JSON_PAYLOADS ? "_payload.json" : "_payload.js";
|
|
40
40
|
let entryPath;
|
|
41
|
-
|
|
41
|
+
const handler = defineRenderHandler(async (event) => {
|
|
42
42
|
const nitroApp = useNitroApp();
|
|
43
43
|
// Whether we're rendering an error page
|
|
44
44
|
const ssrError = event.path.startsWith("/__nuxt_error") ? getQuery(event) : null;
|
|
@@ -281,6 +281,7 @@ export default defineRenderHandler(async (event) => {
|
|
|
281
281
|
}
|
|
282
282
|
};
|
|
283
283
|
});
|
|
284
|
+
export default handler;
|
|
284
285
|
function normalizeChunks(chunks) {
|
|
285
286
|
const result = [];
|
|
286
287
|
for (const _chunk of chunks) {
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import type { EventHandler } from "h3";
|
|
2
|
+
declare const handler: EventHandler;
|
|
3
|
+
export default handler;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { defineEventHandler, getRequestHeader } from "h3";
|
|
2
|
-
|
|
2
|
+
const handler = defineEventHandler((event) => {
|
|
3
3
|
if (getRequestHeader(event, "x-nuxt-no-ssr")) {
|
|
4
4
|
event.context.nuxt ||= {};
|
|
5
5
|
event.context.nuxt.noSSR = true;
|
|
6
6
|
}
|
|
7
7
|
});
|
|
8
|
+
export default handler;
|
|
@@ -1,5 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
export declare const
|
|
3
|
-
export declare const
|
|
4
|
-
export declare const
|
|
5
|
-
export declare const
|
|
1
|
+
import type { Storage } from "unstorage";
|
|
2
|
+
export declare const payloadCache: Storage | null;
|
|
3
|
+
export declare const islandCache: Storage | null;
|
|
4
|
+
export declare const islandPropCache: Storage | null;
|
|
5
|
+
export declare const sharedPrerenderPromises: Map<string, Promise<any>> | null;
|
|
6
|
+
interface SharedPrerenderCache {
|
|
7
|
+
get<T = unknown>(key: string): Promise<T> | undefined;
|
|
8
|
+
set<T>(key: string, value: Promise<T>): Promise<void>;
|
|
9
|
+
}
|
|
10
|
+
export declare const sharedPrerenderCache: SharedPrerenderCache | null;
|
|
11
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const defineAppConfig:
|
|
1
|
+
export declare const defineAppConfig: (config: any) => any;
|
|
@@ -3,4 +3,4 @@ import type { H3Event } from "h3";
|
|
|
3
3
|
* Nitro internal functions extracted from https://github.com/nitrojs/nitro/blob/v2/src/runtime/internal/utils.ts
|
|
4
4
|
*/
|
|
5
5
|
export declare function isJsonRequest(event: H3Event): boolean;
|
|
6
|
-
export declare function hasReqHeader(event: H3Event, name: string, includes: string);
|
|
6
|
+
export declare function hasReqHeader(event: H3Event, name: string, includes: string): boolean;
|
|
@@ -11,5 +11,5 @@ export function isJsonRequest(event) {
|
|
|
11
11
|
}
|
|
12
12
|
export function hasReqHeader(event, name, includes) {
|
|
13
13
|
const value = getRequestHeader(event, name);
|
|
14
|
-
return value && typeof value === "string" && value.toLowerCase().includes(includes);
|
|
14
|
+
return !!(value && typeof value === "string" && value.toLowerCase().includes(includes));
|
|
15
15
|
}
|
|
@@ -10,7 +10,7 @@ interface Renderer {
|
|
|
10
10
|
renderScripts: () => string;
|
|
11
11
|
}>;
|
|
12
12
|
}
|
|
13
|
-
export declare const getSSRRenderer:
|
|
13
|
+
export declare const getSSRRenderer: () => Promise<Renderer>;
|
|
14
14
|
export declare function getRenderer(ssrContext: NuxtSSRContext): Promise<Renderer>;
|
|
15
|
-
export declare const getSSRStyles:
|
|
15
|
+
export declare const getSSRStyles: () => Promise<Record<string, () => Promise<string[]>>>;
|
|
16
16
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuxt/nitro-server-nightly",
|
|
3
|
-
"version": "4.3.2-
|
|
3
|
+
"version": "4.3.2-29531289.6a3bd23e",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/nuxt/nuxt.git",
|
|
@@ -19,9 +19,9 @@
|
|
|
19
19
|
],
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@nuxt/devalue": "^2.0.2",
|
|
22
|
-
"@nuxt/kit": "npm:@nuxt/kit-nightly@4.3.2-
|
|
23
|
-
"@unhead/vue": "^2.1.
|
|
24
|
-
"@vue/shared": "^3.5.
|
|
22
|
+
"@nuxt/kit": "npm:@nuxt/kit-nightly@4.3.2-29531289.6a3bd23e",
|
|
23
|
+
"@unhead/vue": "^2.1.4",
|
|
24
|
+
"@vue/shared": "^3.5.28",
|
|
25
25
|
"consola": "^3.4.2",
|
|
26
26
|
"defu": "^6.1.4",
|
|
27
27
|
"destr": "^2.0.5",
|
|
@@ -42,17 +42,17 @@
|
|
|
42
42
|
"ufo": "^1.6.3",
|
|
43
43
|
"unctx": "^2.5.0",
|
|
44
44
|
"unstorage": "^1.17.4",
|
|
45
|
-
"vue": "^3.5.
|
|
45
|
+
"vue": "^3.5.28",
|
|
46
46
|
"vue-bundle-renderer": "^2.2.0",
|
|
47
47
|
"vue-devtools-stub": "^0.1.0"
|
|
48
48
|
},
|
|
49
49
|
"peerDependencies": {
|
|
50
|
-
"nuxt": "npm:nuxt-nightly@4.3.2-
|
|
50
|
+
"nuxt": "npm:nuxt-nightly@4.3.2-29531289.6a3bd23e"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
|
-
"@nuxt/schema": "npm:@nuxt/schema-nightly@4.3.2-
|
|
54
|
-
"nuxt": "npm:nuxt-nightly@4.3.2-
|
|
55
|
-
"obuild": "0.4.
|
|
53
|
+
"@nuxt/schema": "npm:@nuxt/schema-nightly@4.3.2-29531289.6a3bd23e",
|
|
54
|
+
"nuxt": "npm:nuxt-nightly@4.3.2-29531289.6a3bd23e",
|
|
55
|
+
"obuild": "0.4.31",
|
|
56
56
|
"vitest": "4.0.18"
|
|
57
57
|
},
|
|
58
58
|
"engines": {
|