@bleedingdev/modern-js-runtime 3.9.0-ultramodern.11 → 3.9.0-ultramodern.13
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/cjs/cli/template.server.js +1 -2
- package/dist/cjs/core/browser/hydrate.js +2 -2
- package/dist/cjs/core/server/stream/beforeTemplate.js +3 -3
- package/dist/cjs/core/server/stream/beforeTemplate.worker.js +2 -2
- package/dist/cjs/core/server/string/loadable.js +4 -4
- package/dist/cjs/router/cli/code/nestedRoutes.js +1 -2
- package/dist/cjs/router/cli/code/templates.js +1 -1
- package/dist/cjs/router/cli/code/utils.js +2 -2
- package/dist/cjs/router/runtime/DeferredDataScripts.node.js +10 -9
- package/dist/cjs/router/runtime/plugin.js +8 -17
- package/dist/cjs/router/runtime/plugin.node.js +1 -1
- package/dist/esm/cli/template.server.mjs +1 -2
- package/dist/esm/core/browser/hydrate.mjs +2 -2
- package/dist/esm/core/server/stream/beforeTemplate.mjs +3 -3
- package/dist/esm/core/server/stream/beforeTemplate.worker.mjs +2 -2
- package/dist/esm/core/server/string/loadable.mjs +4 -4
- package/dist/esm/router/cli/code/nestedRoutes.mjs +1 -2
- package/dist/esm/router/cli/code/templates.mjs +1 -1
- package/dist/esm/router/cli/code/utils.mjs +2 -2
- package/dist/esm/router/runtime/DeferredDataScripts.node.mjs +10 -9
- package/dist/esm/router/runtime/plugin.mjs +8 -17
- package/dist/esm/router/runtime/plugin.node.mjs +1 -1
- package/dist/esm-node/cli/template.server.mjs +1 -2
- package/dist/esm-node/core/browser/hydrate.mjs +2 -2
- package/dist/esm-node/core/server/stream/beforeTemplate.mjs +3 -3
- package/dist/esm-node/core/server/stream/beforeTemplate.worker.mjs +2 -2
- package/dist/esm-node/core/server/string/loadable.mjs +4 -4
- package/dist/esm-node/router/cli/code/nestedRoutes.mjs +1 -2
- package/dist/esm-node/router/cli/code/templates.mjs +1 -1
- package/dist/esm-node/router/cli/code/utils.mjs +2 -2
- package/dist/esm-node/router/runtime/DeferredDataScripts.node.mjs +10 -9
- package/dist/esm-node/router/runtime/plugin.mjs +8 -17
- package/dist/esm-node/router/runtime/plugin.node.mjs +1 -1
- package/package.json +18 -18
|
@@ -153,8 +153,7 @@ function genHandlerCode({ mode, metaName, customServerEntry, srcDirectory, inter
|
|
|
153
153
|
return `
|
|
154
154
|
export * from '${realEntryPath}';
|
|
155
155
|
export { default as requestHandler } from '${realEntryPath}'`;
|
|
156
|
-
}
|
|
157
|
-
{
|
|
156
|
+
} else {
|
|
158
157
|
const entrySource = enableRsc ? SERVER_ENTRY_RSC : SERVER_ENTRY;
|
|
159
158
|
const serverEntry = transformServerEntry(entrySource, {
|
|
160
159
|
metaName: metaName || 'modern-js',
|
|
@@ -62,7 +62,7 @@ function hydrateRoot(App, context, ModernRender, ModernHydrate) {
|
|
|
62
62
|
if ('stream' === renderMode) return streamSSRHydrate();
|
|
63
63
|
function streamSSRHydrate() {
|
|
64
64
|
if (renderLevel !== external_constants_js_namespaceObject.RenderLevel.SERVER_RENDER) return ModernRender((0, wrapper_js_namespaceObject.wrapRuntimeContextProvider)(App, context));
|
|
65
|
-
{
|
|
65
|
+
else {
|
|
66
66
|
const SSRApp = ()=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_withCallback_js_namespaceObject.WithCallback, {
|
|
67
67
|
callback: callback,
|
|
68
68
|
children: App
|
|
@@ -78,7 +78,7 @@ function hydrateRoot(App, context, ModernRender, ModernHydrate) {
|
|
|
78
78
|
return stringSSRHydrate();
|
|
79
79
|
function stringSSRHydrate() {
|
|
80
80
|
if (renderLevel === external_constants_js_namespaceObject.RenderLevel.CLIENT_RENDER) return ModernRender((0, wrapper_js_namespaceObject.wrapRuntimeContextProvider)(App, context));
|
|
81
|
-
{
|
|
81
|
+
else {
|
|
82
82
|
if (renderLevel === external_constants_js_namespaceObject.RenderLevel.SERVER_RENDER) return (0, component_namespaceObject.loadableReady)(()=>void 0, loadableReadyOptions).then(()=>{
|
|
83
83
|
const SSRApp = ()=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_withCallback_js_namespaceObject.WithCallback, {
|
|
84
84
|
callback: callback,
|
|
@@ -43,8 +43,8 @@ const readAsset = async (chunk)=>{
|
|
|
43
43
|
};
|
|
44
44
|
const checkIsInline = (chunk, enableInline)=>{
|
|
45
45
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
46
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
47
|
-
return Boolean(enableInline);
|
|
46
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
47
|
+
else return Boolean(enableInline);
|
|
48
48
|
};
|
|
49
49
|
async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
50
50
|
const { config, runtimeContext, styledComponentsStyleTags, entryName, lifecycle, helmetData } = options;
|
|
@@ -102,7 +102,7 @@ async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
|
102
102
|
const styles = await Promise.all(cssChunks.map(async (chunk)=>{
|
|
103
103
|
const link = `<link href="${chunk}" rel="stylesheet" />`;
|
|
104
104
|
if ((0, external_utils_js_namespaceObject.checkIsNode)() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<style>${content}</style>`).catch((_)=>link);
|
|
105
|
-
return link;
|
|
105
|
+
else return link;
|
|
106
106
|
}));
|
|
107
107
|
return `${styles.join('')}`;
|
|
108
108
|
}
|
|
@@ -36,8 +36,8 @@ const external_shared_js_namespaceObject = require("../shared.js");
|
|
|
36
36
|
const external_utils_js_namespaceObject = require("../utils.js");
|
|
37
37
|
const checkIsInline = (chunk, enableInline)=>{
|
|
38
38
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
39
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
40
|
-
return Boolean(enableInline);
|
|
39
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
40
|
+
else return Boolean(enableInline);
|
|
41
41
|
};
|
|
42
42
|
async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
43
43
|
const { config, runtimeContext, styledComponentsStyleTags, entryName, lifecycle, helmetData } = options;
|
|
@@ -48,8 +48,8 @@ const assetToChunk = (asset)=>({
|
|
|
48
48
|
});
|
|
49
49
|
const checkIsInline = (chunk, enableInline)=>{
|
|
50
50
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
51
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk.url);
|
|
52
|
-
return Boolean(enableInline);
|
|
51
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk.url);
|
|
52
|
+
else return Boolean(enableInline);
|
|
53
53
|
};
|
|
54
54
|
const readAsset = async (chunk)=>{
|
|
55
55
|
const fs = await import("fs/promises");
|
|
@@ -142,7 +142,7 @@ class LoadableCollector {
|
|
|
142
142
|
const scripts = await Promise.all(chunks.filter((chunk)=>!existedScript.includes(chunk.url) && !this.existsAssets?.includes(chunk.path)).map(async (chunk)=>{
|
|
143
143
|
const script = `<script${attributes} src="${chunk.url}"></script>`;
|
|
144
144
|
if ((0, external_utils_js_namespaceObject.checkIsNode)() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<script>${content}</script>`).catch((_)=>script);
|
|
145
|
-
return script;
|
|
145
|
+
else return script;
|
|
146
146
|
}));
|
|
147
147
|
chunkSet.jsChunk += scripts.filter((script)=>Boolean(script)).join('');
|
|
148
148
|
}
|
|
@@ -159,7 +159,7 @@ class LoadableCollector {
|
|
|
159
159
|
const css = await Promise.all(emittedChunks.map(async (chunk)=>{
|
|
160
160
|
const link = `<link${atrributes} href="${chunk.url}" rel="stylesheet" />`;
|
|
161
161
|
if ((0, external_utils_js_namespaceObject.checkIsNode)() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<style>${content}</style>`).catch((_)=>link);
|
|
162
|
-
return link;
|
|
162
|
+
else return link;
|
|
163
163
|
}));
|
|
164
164
|
chunkSet.cssChunk += css.filter((css)=>Boolean(css)).join('');
|
|
165
165
|
this.stylesheetInfo.emittedAssets = emittedChunks.map((chunk)=>chunk.url);
|
|
@@ -76,8 +76,7 @@ const optimizeRoute = (routeTree)=>{
|
|
|
76
76
|
children: optimizedChildren
|
|
77
77
|
}
|
|
78
78
|
];
|
|
79
|
-
}
|
|
80
|
-
{
|
|
79
|
+
} else {
|
|
81
80
|
const newRoutes = children.map((child)=>{
|
|
82
81
|
const routePath = routeTree.path ? `${routeTree.path}${child.path ? `/${child.path}` : ''}` : child.path || '';
|
|
83
82
|
const newRoute = {
|
|
@@ -61,7 +61,7 @@ const walkDirectory = (dir)=>external_fs_default().readdirSync(dir).reduce((prev
|
|
|
61
61
|
...previous,
|
|
62
62
|
...walkDirectory(filePath)
|
|
63
63
|
];
|
|
64
|
-
return [
|
|
64
|
+
else return [
|
|
65
65
|
...previous,
|
|
66
66
|
filePath
|
|
67
67
|
];
|
|
@@ -78,7 +78,7 @@ const isPageComponentFile = (filePath)=>{
|
|
|
78
78
|
};
|
|
79
79
|
const replaceWithAlias = (base, filePath, alias)=>{
|
|
80
80
|
if (filePath.includes(base)) return (0, utils_namespaceObject.normalizeToPosixPath)(external_path_default().join(alias, external_path_default().relative(base, filePath)));
|
|
81
|
-
return filePath;
|
|
81
|
+
else return filePath;
|
|
82
82
|
};
|
|
83
83
|
const parseModule = async ({ source, filename })=>{
|
|
84
84
|
let content = source;
|
|
@@ -83,7 +83,7 @@ const DeferredDataScripts = (props)=>{
|
|
|
83
83
|
(0, node_namespaceObject.serializeJson)(key)
|
|
84
84
|
]
|
|
85
85
|
};
|
|
86
|
-
{
|
|
86
|
+
else {
|
|
87
87
|
const trackedPromise = deferredData.data[key];
|
|
88
88
|
if (void 0 !== trackedPromise._error) {
|
|
89
89
|
const error = toDeferredErrorInfo(trackedPromise._error);
|
|
@@ -95,15 +95,16 @@ const DeferredDataScripts = (props)=>{
|
|
|
95
95
|
(0, node_namespaceObject.serializeJson)(error)
|
|
96
96
|
]
|
|
97
97
|
};
|
|
98
|
+
} else {
|
|
99
|
+
if (void 0 === trackedPromise._data) throw new Error(`The deferred data for ${key} was not resolved, did you forget to return data from a deferred promise`);
|
|
100
|
+
return {
|
|
101
|
+
key,
|
|
102
|
+
routerDataFnName: 'p',
|
|
103
|
+
routerDataFnArgs: [
|
|
104
|
+
(0, node_namespaceObject.serializeJson)(trackedPromise._data)
|
|
105
|
+
]
|
|
106
|
+
};
|
|
98
107
|
}
|
|
99
|
-
if (void 0 === trackedPromise._data) throw new Error(`The deferred data for ${key} was not resolved, did you forget to return data from a deferred promise`);
|
|
100
|
-
return {
|
|
101
|
-
key,
|
|
102
|
-
routerDataFnName: 'p',
|
|
103
|
-
routerDataFnArgs: [
|
|
104
|
-
(0, node_namespaceObject.serializeJson)(trackedPromise._data)
|
|
105
|
-
]
|
|
106
|
-
};
|
|
107
108
|
}
|
|
108
109
|
});
|
|
109
110
|
return {
|
|
@@ -101,7 +101,6 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
101
101
|
const match = serverBase.find((baseUrl)=>isSegmentPrefix(pathname, baseUrl));
|
|
102
102
|
return match || '/';
|
|
103
103
|
};
|
|
104
|
-
let cachedRouter = null;
|
|
105
104
|
const RouterWrapper = (props)=>{
|
|
106
105
|
const routerResult = useRouterCreation(("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === (0, index_js_namespaceObject.getGlobalEnableRsc)()) ? {
|
|
107
106
|
...props,
|
|
@@ -113,12 +112,7 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
113
112
|
selectBasePath,
|
|
114
113
|
basename
|
|
115
114
|
});
|
|
116
|
-
const router =
|
|
117
|
-
if (cachedRouter) return cachedRouter;
|
|
118
|
-
cachedRouter = routerResult.router;
|
|
119
|
-
return cachedRouter;
|
|
120
|
-
}, []);
|
|
121
|
-
const { routes } = routerResult;
|
|
115
|
+
const { router, routes } = routerResult;
|
|
122
116
|
routesContainer.current = routes;
|
|
123
117
|
beforeCreateRouter = false;
|
|
124
118
|
const routerContent = /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(jsx_runtime_namespaceObject.Fragment, {
|
|
@@ -162,7 +156,8 @@ function useRouterCreation(props, options) {
|
|
|
162
156
|
const { unstable_getBlockNavState: getBlockNavState } = runtimeContext;
|
|
163
157
|
const rscPayload = ("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === (0, index_js_namespaceObject.getGlobalEnableRsc)()) && props?.rscPayload ? safeUse(props.rscPayload) : null;
|
|
164
158
|
let hydrationData = "u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ ? window._ROUTER_DATA || rscPayload : window._ROUTER_DATA : true === (0, index_js_namespaceObject.getGlobalEnableRsc)() ? window._ROUTER_DATA || rscPayload : window._ROUTER_DATA;
|
|
165
|
-
|
|
159
|
+
const result = (0, external_react_namespaceObject.useRef)(null);
|
|
160
|
+
if (null === result.current) {
|
|
166
161
|
if (hydrationData?.errors) hydrationData = {
|
|
167
162
|
...hydrationData,
|
|
168
163
|
errors: (0, external_utils_js_namespaceObject.deserializeErrors)(hydrationData.errors)
|
|
@@ -178,10 +173,11 @@ function useRouterCreation(props, options) {
|
|
|
178
173
|
const hooks = api.getHooks();
|
|
179
174
|
if (("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === (0, index_js_namespaceObject.getGlobalEnableRsc)()) && rscPayload) try {
|
|
180
175
|
const router = (0, external_rsc_router_js_namespaceObject.createClientRouterFromPayload)(rscPayload, routes, _basename);
|
|
181
|
-
|
|
176
|
+
result.current = {
|
|
182
177
|
router,
|
|
183
178
|
routes: router.routes || []
|
|
184
179
|
};
|
|
180
|
+
return result.current;
|
|
185
181
|
} catch (e) {
|
|
186
182
|
console.error('Failed to create router from RSC payload:', e);
|
|
187
183
|
}
|
|
@@ -230,17 +226,12 @@ function useRouterCreation(props, options) {
|
|
|
230
226
|
};
|
|
231
227
|
return originSubscribe(wrappedListener);
|
|
232
228
|
};
|
|
233
|
-
|
|
229
|
+
result.current = {
|
|
234
230
|
router,
|
|
235
231
|
routes: modifiedRoutes
|
|
236
232
|
};
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
props,
|
|
240
|
-
_basename,
|
|
241
|
-
hydrationData,
|
|
242
|
-
getBlockNavState
|
|
243
|
-
]);
|
|
233
|
+
}
|
|
234
|
+
return result.current;
|
|
244
235
|
}
|
|
245
236
|
exports.beforeCreateRouter = __webpack_exports__.beforeCreateRouter;
|
|
246
237
|
exports.finalRouteConfig = __webpack_exports__.finalRouteConfig;
|
|
@@ -166,7 +166,7 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
166
166
|
}) : /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_rsc_router_js_namespaceObject.RSCStaticRouter, {
|
|
167
167
|
basename: basename
|
|
168
168
|
});
|
|
169
|
-
{
|
|
169
|
+
else {
|
|
170
170
|
const { nonce, mode, useJsonScript } = context.ssrContext;
|
|
171
171
|
const remixRouter = (0, router_namespaceObject.createStaticRouter)(routes, routerContext);
|
|
172
172
|
const routerWrapper = /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(jsx_runtime_namespaceObject.Fragment, {
|
|
@@ -120,8 +120,7 @@ function genHandlerCode({ mode, metaName, customServerEntry, srcDirectory, inter
|
|
|
120
120
|
return `
|
|
121
121
|
export * from '${realEntryPath}';
|
|
122
122
|
export { default as requestHandler } from '${realEntryPath}'`;
|
|
123
|
-
}
|
|
124
|
-
{
|
|
123
|
+
} else {
|
|
125
124
|
const entrySource = enableRsc ? SERVER_ENTRY_RSC : SERVER_ENTRY;
|
|
126
125
|
const serverEntry = transformServerEntry(entrySource, {
|
|
127
126
|
metaName: metaName || 'modern-js',
|
|
@@ -29,7 +29,7 @@ function hydrate_hydrateRoot(App, context, ModernRender, ModernHydrate) {
|
|
|
29
29
|
if ('stream' === renderMode) return streamSSRHydrate();
|
|
30
30
|
function streamSSRHydrate() {
|
|
31
31
|
if (renderLevel !== RenderLevel.SERVER_RENDER) return ModernRender(wrapRuntimeContextProvider(App, context));
|
|
32
|
-
{
|
|
32
|
+
else {
|
|
33
33
|
const SSRApp = ()=>/*#__PURE__*/ jsx(WithCallback, {
|
|
34
34
|
callback: callback,
|
|
35
35
|
children: App
|
|
@@ -45,7 +45,7 @@ function hydrate_hydrateRoot(App, context, ModernRender, ModernHydrate) {
|
|
|
45
45
|
return stringSSRHydrate();
|
|
46
46
|
function stringSSRHydrate() {
|
|
47
47
|
if (renderLevel === RenderLevel.CLIENT_RENDER) return ModernRender(wrapRuntimeContextProvider(App, context));
|
|
48
|
-
{
|
|
48
|
+
else {
|
|
49
49
|
if (renderLevel === RenderLevel.SERVER_RENDER) return loadableReady(()=>void 0, loadableReadyOptions).then(()=>{
|
|
50
50
|
const SSRApp = ()=>/*#__PURE__*/ jsx(WithCallback, {
|
|
51
51
|
callback: callback,
|
|
@@ -11,8 +11,8 @@ const readAsset = async (chunk)=>{
|
|
|
11
11
|
};
|
|
12
12
|
const checkIsInline = (chunk, enableInline)=>{
|
|
13
13
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
14
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
15
|
-
return Boolean(enableInline);
|
|
14
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
15
|
+
else return Boolean(enableInline);
|
|
16
16
|
};
|
|
17
17
|
async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
18
18
|
const { config, runtimeContext, styledComponentsStyleTags, entryName, lifecycle, helmetData } = options;
|
|
@@ -70,7 +70,7 @@ async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
|
70
70
|
const styles = await Promise.all(cssChunks.map(async (chunk)=>{
|
|
71
71
|
const link = `<link href="${chunk}" rel="stylesheet" />`;
|
|
72
72
|
if (checkIsNode() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<style>${content}</style>`).catch((_)=>link);
|
|
73
|
-
return link;
|
|
73
|
+
else return link;
|
|
74
74
|
}));
|
|
75
75
|
return `${styles.join('')}`;
|
|
76
76
|
}
|
|
@@ -4,8 +4,8 @@ import { buildHtml, replaceSSRTemplateChunk } from "../shared.mjs";
|
|
|
4
4
|
import { hasStylesheetLink } from "../utils.mjs";
|
|
5
5
|
const checkIsInline = (chunk, enableInline)=>{
|
|
6
6
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
7
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
8
|
-
return Boolean(enableInline);
|
|
7
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
8
|
+
else return Boolean(enableInline);
|
|
9
9
|
};
|
|
10
10
|
async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
11
11
|
const { config, runtimeContext, styledComponentsStyleTags, entryName, lifecycle, helmetData } = options;
|
|
@@ -16,8 +16,8 @@ const assetToChunk = (asset)=>({
|
|
|
16
16
|
});
|
|
17
17
|
const checkIsInline = (chunk, enableInline)=>{
|
|
18
18
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
19
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk.url);
|
|
20
|
-
return Boolean(enableInline);
|
|
19
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk.url);
|
|
20
|
+
else return Boolean(enableInline);
|
|
21
21
|
};
|
|
22
22
|
const readAsset = async (chunk)=>{
|
|
23
23
|
const fs = await import("fs/promises");
|
|
@@ -110,7 +110,7 @@ class LoadableCollector {
|
|
|
110
110
|
const scripts = await Promise.all(chunks.filter((chunk)=>!existedScript.includes(chunk.url) && !this.existsAssets?.includes(chunk.path)).map(async (chunk)=>{
|
|
111
111
|
const script = `<script${attributes} src="${chunk.url}"></script>`;
|
|
112
112
|
if (checkIsNode() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<script>${content}</script>`).catch((_)=>script);
|
|
113
|
-
return script;
|
|
113
|
+
else return script;
|
|
114
114
|
}));
|
|
115
115
|
chunkSet.jsChunk += scripts.filter((script)=>Boolean(script)).join('');
|
|
116
116
|
}
|
|
@@ -127,7 +127,7 @@ class LoadableCollector {
|
|
|
127
127
|
const css = await Promise.all(emittedChunks.map(async (chunk)=>{
|
|
128
128
|
const link = `<link${atrributes} href="${chunk.url}" rel="stylesheet" />`;
|
|
129
129
|
if (checkIsNode() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<style>${content}</style>`).catch((_)=>link);
|
|
130
|
-
return link;
|
|
130
|
+
else return link;
|
|
131
131
|
}));
|
|
132
132
|
chunkSet.cssChunk += css.filter((css)=>Boolean(css)).join('');
|
|
133
133
|
this.stylesheetInfo.emittedAssets = emittedChunks.map((chunk)=>chunk.url);
|
|
@@ -42,8 +42,7 @@ const optimizeRoute = (routeTree)=>{
|
|
|
42
42
|
children: optimizedChildren
|
|
43
43
|
}
|
|
44
44
|
];
|
|
45
|
-
}
|
|
46
|
-
{
|
|
45
|
+
} else {
|
|
47
46
|
const newRoutes = children.map((child)=>{
|
|
48
47
|
const routePath = routeTree.path ? `${routeTree.path}${child.path ? `/${child.path}` : ''}` : child.path || '';
|
|
49
48
|
const newRoute = {
|
|
@@ -10,7 +10,7 @@ const walkDirectory = (dir)=>fs_0.readdirSync(dir).reduce((previous, filename)=>
|
|
|
10
10
|
...previous,
|
|
11
11
|
...walkDirectory(filePath)
|
|
12
12
|
];
|
|
13
|
-
return [
|
|
13
|
+
else return [
|
|
14
14
|
...previous,
|
|
15
15
|
filePath
|
|
16
16
|
];
|
|
@@ -27,7 +27,7 @@ const isPageComponentFile = (filePath)=>{
|
|
|
27
27
|
};
|
|
28
28
|
const replaceWithAlias = (base, filePath, alias)=>{
|
|
29
29
|
if (filePath.includes(base)) return normalizeToPosixPath(path.join(alias, path.relative(base, filePath)));
|
|
30
|
-
return filePath;
|
|
30
|
+
else return filePath;
|
|
31
31
|
};
|
|
32
32
|
const parseModule = async ({ source, filename })=>{
|
|
33
33
|
let content = source;
|
|
@@ -51,7 +51,7 @@ const DeferredDataScripts = (props)=>{
|
|
|
51
51
|
serializeJson(key)
|
|
52
52
|
]
|
|
53
53
|
};
|
|
54
|
-
{
|
|
54
|
+
else {
|
|
55
55
|
const trackedPromise = deferredData.data[key];
|
|
56
56
|
if (void 0 !== trackedPromise._error) {
|
|
57
57
|
const error = toDeferredErrorInfo(trackedPromise._error);
|
|
@@ -63,15 +63,16 @@ const DeferredDataScripts = (props)=>{
|
|
|
63
63
|
serializeJson(error)
|
|
64
64
|
]
|
|
65
65
|
};
|
|
66
|
+
} else {
|
|
67
|
+
if (void 0 === trackedPromise._data) throw new Error(`The deferred data for ${key} was not resolved, did you forget to return data from a deferred promise`);
|
|
68
|
+
return {
|
|
69
|
+
key,
|
|
70
|
+
routerDataFnName: 'p',
|
|
71
|
+
routerDataFnArgs: [
|
|
72
|
+
serializeJson(trackedPromise._data)
|
|
73
|
+
]
|
|
74
|
+
};
|
|
66
75
|
}
|
|
67
|
-
if (void 0 === trackedPromise._data) throw new Error(`The deferred data for ${key} was not resolved, did you forget to return data from a deferred promise`);
|
|
68
|
-
return {
|
|
69
|
-
key,
|
|
70
|
-
routerDataFnName: 'p',
|
|
71
|
-
routerDataFnArgs: [
|
|
72
|
-
serializeJson(trackedPromise._data)
|
|
73
|
-
]
|
|
74
|
-
};
|
|
75
76
|
}
|
|
76
77
|
});
|
|
77
78
|
return {
|
|
@@ -66,7 +66,6 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
66
66
|
const match = serverBase.find((baseUrl)=>isSegmentPrefix(pathname, baseUrl));
|
|
67
67
|
return match || '/';
|
|
68
68
|
};
|
|
69
|
-
let cachedRouter = null;
|
|
70
69
|
const RouterWrapper = (props)=>{
|
|
71
70
|
const routerResult = useRouterCreation(("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === getGlobalEnableRsc()) ? {
|
|
72
71
|
...props,
|
|
@@ -78,12 +77,7 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
78
77
|
selectBasePath,
|
|
79
78
|
basename
|
|
80
79
|
});
|
|
81
|
-
const router =
|
|
82
|
-
if (cachedRouter) return cachedRouter;
|
|
83
|
-
cachedRouter = routerResult.router;
|
|
84
|
-
return cachedRouter;
|
|
85
|
-
}, []);
|
|
86
|
-
const { routes } = routerResult;
|
|
80
|
+
const { router, routes } = routerResult;
|
|
87
81
|
routesContainer.current = routes;
|
|
88
82
|
beforeCreateRouter = false;
|
|
89
83
|
const routerContent = /*#__PURE__*/ jsxs(Fragment, {
|
|
@@ -127,7 +121,8 @@ function useRouterCreation(props, options) {
|
|
|
127
121
|
const { unstable_getBlockNavState: getBlockNavState } = runtimeContext;
|
|
128
122
|
const rscPayload = ("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === getGlobalEnableRsc()) && props?.rscPayload ? safeUse(props.rscPayload) : null;
|
|
129
123
|
let hydrationData = "u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ ? window._ROUTER_DATA || rscPayload : window._ROUTER_DATA : true === getGlobalEnableRsc() ? window._ROUTER_DATA || rscPayload : window._ROUTER_DATA;
|
|
130
|
-
|
|
124
|
+
const result = (0, __rspack_external_react.useRef)(null);
|
|
125
|
+
if (null === result.current) {
|
|
131
126
|
if (hydrationData?.errors) hydrationData = {
|
|
132
127
|
...hydrationData,
|
|
133
128
|
errors: deserializeErrors(hydrationData.errors)
|
|
@@ -143,10 +138,11 @@ function useRouterCreation(props, options) {
|
|
|
143
138
|
const hooks = api.getHooks();
|
|
144
139
|
if (("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === getGlobalEnableRsc()) && rscPayload) try {
|
|
145
140
|
const router = createClientRouterFromPayload(rscPayload, routes, _basename);
|
|
146
|
-
|
|
141
|
+
result.current = {
|
|
147
142
|
router,
|
|
148
143
|
routes: router.routes || []
|
|
149
144
|
};
|
|
145
|
+
return result.current;
|
|
150
146
|
} catch (e) {
|
|
151
147
|
console.error('Failed to create router from RSC payload:', e);
|
|
152
148
|
}
|
|
@@ -195,16 +191,11 @@ function useRouterCreation(props, options) {
|
|
|
195
191
|
};
|
|
196
192
|
return originSubscribe(wrappedListener);
|
|
197
193
|
};
|
|
198
|
-
|
|
194
|
+
result.current = {
|
|
199
195
|
router,
|
|
200
196
|
routes: modifiedRoutes
|
|
201
197
|
};
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
props,
|
|
205
|
-
_basename,
|
|
206
|
-
hydrationData,
|
|
207
|
-
getBlockNavState
|
|
208
|
-
]);
|
|
198
|
+
}
|
|
199
|
+
return result.current;
|
|
209
200
|
}
|
|
210
201
|
export { beforeCreateRouter, finalRouteConfig, modifyRoutes, routerPlugin };
|
|
@@ -123,7 +123,7 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
123
123
|
}) : /*#__PURE__*/ jsx(RSCStaticRouter, {
|
|
124
124
|
basename: basename
|
|
125
125
|
});
|
|
126
|
-
{
|
|
126
|
+
else {
|
|
127
127
|
const { nonce, mode, useJsonScript } = context.ssrContext;
|
|
128
128
|
const remixRouter = createStaticRouter(routes, routerContext);
|
|
129
129
|
const routerWrapper = /*#__PURE__*/ jsxs(Fragment, {
|
|
@@ -121,8 +121,7 @@ function genHandlerCode({ mode, metaName, customServerEntry, srcDirectory, inter
|
|
|
121
121
|
return `
|
|
122
122
|
export * from '${realEntryPath}';
|
|
123
123
|
export { default as requestHandler } from '${realEntryPath}'`;
|
|
124
|
-
}
|
|
125
|
-
{
|
|
124
|
+
} else {
|
|
126
125
|
const entrySource = enableRsc ? SERVER_ENTRY_RSC : SERVER_ENTRY;
|
|
127
126
|
const serverEntry = transformServerEntry(entrySource, {
|
|
128
127
|
metaName: metaName || 'modern-js',
|
|
@@ -30,7 +30,7 @@ function hydrate_hydrateRoot(App, context, ModernRender, ModernHydrate) {
|
|
|
30
30
|
if ('stream' === renderMode) return streamSSRHydrate();
|
|
31
31
|
function streamSSRHydrate() {
|
|
32
32
|
if (renderLevel !== RenderLevel.SERVER_RENDER) return ModernRender(wrapRuntimeContextProvider(App, context));
|
|
33
|
-
{
|
|
33
|
+
else {
|
|
34
34
|
const SSRApp = ()=>/*#__PURE__*/ jsx(WithCallback, {
|
|
35
35
|
callback: callback,
|
|
36
36
|
children: App
|
|
@@ -46,7 +46,7 @@ function hydrate_hydrateRoot(App, context, ModernRender, ModernHydrate) {
|
|
|
46
46
|
return stringSSRHydrate();
|
|
47
47
|
function stringSSRHydrate() {
|
|
48
48
|
if (renderLevel === RenderLevel.CLIENT_RENDER) return ModernRender(wrapRuntimeContextProvider(App, context));
|
|
49
|
-
{
|
|
49
|
+
else {
|
|
50
50
|
if (renderLevel === RenderLevel.SERVER_RENDER) return loadableReady(()=>void 0, loadableReadyOptions).then(()=>{
|
|
51
51
|
const SSRApp = ()=>/*#__PURE__*/ jsx(WithCallback, {
|
|
52
52
|
callback: callback,
|
|
@@ -15,8 +15,8 @@ const readAsset = async (chunk)=>{
|
|
|
15
15
|
};
|
|
16
16
|
const checkIsInline = (chunk, enableInline)=>{
|
|
17
17
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
18
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
19
|
-
return Boolean(enableInline);
|
|
18
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
19
|
+
else return Boolean(enableInline);
|
|
20
20
|
};
|
|
21
21
|
async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
22
22
|
const { config, runtimeContext, styledComponentsStyleTags, entryName, lifecycle, helmetData } = options;
|
|
@@ -74,7 +74,7 @@ async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
|
74
74
|
const styles = await Promise.all(cssChunks.map(async (chunk)=>{
|
|
75
75
|
const link = `<link href="${chunk}" rel="stylesheet" />`;
|
|
76
76
|
if (checkIsNode() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<style>${content}</style>`).catch((_)=>link);
|
|
77
|
-
return link;
|
|
77
|
+
else return link;
|
|
78
78
|
}));
|
|
79
79
|
return `${styles.join('')}`;
|
|
80
80
|
}
|
|
@@ -5,8 +5,8 @@ import { buildHtml, replaceSSRTemplateChunk } from "../shared.mjs";
|
|
|
5
5
|
import { hasStylesheetLink } from "../utils.mjs";
|
|
6
6
|
const checkIsInline = (chunk, enableInline)=>{
|
|
7
7
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
8
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
9
|
-
return Boolean(enableInline);
|
|
8
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk);
|
|
9
|
+
else return Boolean(enableInline);
|
|
10
10
|
};
|
|
11
11
|
async function buildShellBeforeTemplate(beforeAppTemplate, options) {
|
|
12
12
|
const { config, runtimeContext, styledComponentsStyleTags, entryName, lifecycle, helmetData } = options;
|
|
@@ -20,8 +20,8 @@ const assetToChunk = (asset)=>({
|
|
|
20
20
|
});
|
|
21
21
|
const checkIsInline = (chunk, enableInline)=>{
|
|
22
22
|
if ('production' !== process.env.NODE_ENV) return false;
|
|
23
|
-
if (enableInline instanceof RegExp) return enableInline.test(chunk.url);
|
|
24
|
-
return Boolean(enableInline);
|
|
23
|
+
else if (enableInline instanceof RegExp) return enableInline.test(chunk.url);
|
|
24
|
+
else return Boolean(enableInline);
|
|
25
25
|
};
|
|
26
26
|
const readAsset = async (chunk)=>{
|
|
27
27
|
const fs = await import("fs/promises");
|
|
@@ -114,7 +114,7 @@ class LoadableCollector {
|
|
|
114
114
|
const scripts = await Promise.all(chunks.filter((chunk)=>!existedScript.includes(chunk.url) && !this.existsAssets?.includes(chunk.path)).map(async (chunk)=>{
|
|
115
115
|
const script = `<script${attributes} src="${chunk.url}"></script>`;
|
|
116
116
|
if (checkIsNode() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<script>${content}</script>`).catch((_)=>script);
|
|
117
|
-
return script;
|
|
117
|
+
else return script;
|
|
118
118
|
}));
|
|
119
119
|
chunkSet.jsChunk += scripts.filter((script)=>Boolean(script)).join('');
|
|
120
120
|
}
|
|
@@ -131,7 +131,7 @@ class LoadableCollector {
|
|
|
131
131
|
const css = await Promise.all(emittedChunks.map(async (chunk)=>{
|
|
132
132
|
const link = `<link${atrributes} href="${chunk.url}" rel="stylesheet" />`;
|
|
133
133
|
if (checkIsNode() && checkIsInline(chunk, inlineStyles)) return readAsset(chunk).then((content)=>`<style>${content}</style>`).catch((_)=>link);
|
|
134
|
-
return link;
|
|
134
|
+
else return link;
|
|
135
135
|
}));
|
|
136
136
|
chunkSet.cssChunk += css.filter((css)=>Boolean(css)).join('');
|
|
137
137
|
this.stylesheetInfo.emittedAssets = emittedChunks.map((chunk)=>chunk.url);
|
|
@@ -43,8 +43,7 @@ const optimizeRoute = (routeTree)=>{
|
|
|
43
43
|
children: optimizedChildren
|
|
44
44
|
}
|
|
45
45
|
];
|
|
46
|
-
}
|
|
47
|
-
{
|
|
46
|
+
} else {
|
|
48
47
|
const newRoutes = children.map((child)=>{
|
|
49
48
|
const routePath = routeTree.path ? `${routeTree.path}${child.path ? `/${child.path}` : ''}` : child.path || '';
|
|
50
49
|
const newRoute = {
|
|
@@ -11,7 +11,7 @@ const walkDirectory = (dir)=>fs_0.readdirSync(dir).reduce((previous, filename)=>
|
|
|
11
11
|
...previous,
|
|
12
12
|
...walkDirectory(filePath)
|
|
13
13
|
];
|
|
14
|
-
return [
|
|
14
|
+
else return [
|
|
15
15
|
...previous,
|
|
16
16
|
filePath
|
|
17
17
|
];
|
|
@@ -28,7 +28,7 @@ const isPageComponentFile = (filePath)=>{
|
|
|
28
28
|
};
|
|
29
29
|
const replaceWithAlias = (base, filePath, alias)=>{
|
|
30
30
|
if (filePath.includes(base)) return normalizeToPosixPath(path.join(alias, path.relative(base, filePath)));
|
|
31
|
-
return filePath;
|
|
31
|
+
else return filePath;
|
|
32
32
|
};
|
|
33
33
|
const parseModule = async ({ source, filename })=>{
|
|
34
34
|
let content = source;
|
|
@@ -52,7 +52,7 @@ const DeferredDataScripts = (props)=>{
|
|
|
52
52
|
serializeJson(key)
|
|
53
53
|
]
|
|
54
54
|
};
|
|
55
|
-
{
|
|
55
|
+
else {
|
|
56
56
|
const trackedPromise = deferredData.data[key];
|
|
57
57
|
if (void 0 !== trackedPromise._error) {
|
|
58
58
|
const error = toDeferredErrorInfo(trackedPromise._error);
|
|
@@ -64,15 +64,16 @@ const DeferredDataScripts = (props)=>{
|
|
|
64
64
|
serializeJson(error)
|
|
65
65
|
]
|
|
66
66
|
};
|
|
67
|
+
} else {
|
|
68
|
+
if (void 0 === trackedPromise._data) throw new Error(`The deferred data for ${key} was not resolved, did you forget to return data from a deferred promise`);
|
|
69
|
+
return {
|
|
70
|
+
key,
|
|
71
|
+
routerDataFnName: 'p',
|
|
72
|
+
routerDataFnArgs: [
|
|
73
|
+
serializeJson(trackedPromise._data)
|
|
74
|
+
]
|
|
75
|
+
};
|
|
67
76
|
}
|
|
68
|
-
if (void 0 === trackedPromise._data) throw new Error(`The deferred data for ${key} was not resolved, did you forget to return data from a deferred promise`);
|
|
69
|
-
return {
|
|
70
|
-
key,
|
|
71
|
-
routerDataFnName: 'p',
|
|
72
|
-
routerDataFnArgs: [
|
|
73
|
-
serializeJson(trackedPromise._data)
|
|
74
|
-
]
|
|
75
|
-
};
|
|
76
77
|
}
|
|
77
78
|
});
|
|
78
79
|
return {
|
|
@@ -67,7 +67,6 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
67
67
|
const match = serverBase.find((baseUrl)=>isSegmentPrefix(pathname, baseUrl));
|
|
68
68
|
return match || '/';
|
|
69
69
|
};
|
|
70
|
-
let cachedRouter = null;
|
|
71
70
|
const RouterWrapper = (props)=>{
|
|
72
71
|
const routerResult = useRouterCreation(("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === getGlobalEnableRsc()) ? {
|
|
73
72
|
...props,
|
|
@@ -79,12 +78,7 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
79
78
|
selectBasePath,
|
|
80
79
|
basename
|
|
81
80
|
});
|
|
82
|
-
const router =
|
|
83
|
-
if (cachedRouter) return cachedRouter;
|
|
84
|
-
cachedRouter = routerResult.router;
|
|
85
|
-
return cachedRouter;
|
|
86
|
-
}, []);
|
|
87
|
-
const { routes } = routerResult;
|
|
81
|
+
const { router, routes } = routerResult;
|
|
88
82
|
routesContainer.current = routes;
|
|
89
83
|
beforeCreateRouter = false;
|
|
90
84
|
const routerContent = /*#__PURE__*/ jsxs(Fragment, {
|
|
@@ -128,7 +122,8 @@ function useRouterCreation(props, options) {
|
|
|
128
122
|
const { unstable_getBlockNavState: getBlockNavState } = runtimeContext;
|
|
129
123
|
const rscPayload = ("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === getGlobalEnableRsc()) && props?.rscPayload ? safeUse(props.rscPayload) : null;
|
|
130
124
|
let hydrationData = "u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ ? window._ROUTER_DATA || rscPayload : window._ROUTER_DATA : true === getGlobalEnableRsc() ? window._ROUTER_DATA || rscPayload : window._ROUTER_DATA;
|
|
131
|
-
|
|
125
|
+
const result = (0, __rspack_external_react.useRef)(null);
|
|
126
|
+
if (null === result.current) {
|
|
132
127
|
if (hydrationData?.errors) hydrationData = {
|
|
133
128
|
...hydrationData,
|
|
134
129
|
errors: deserializeErrors(hydrationData.errors)
|
|
@@ -144,10 +139,11 @@ function useRouterCreation(props, options) {
|
|
|
144
139
|
const hooks = api.getHooks();
|
|
145
140
|
if (("u" > typeof __MODERN_ENABLE_RSC__ ? __MODERN_ENABLE_RSC__ : true === getGlobalEnableRsc()) && rscPayload) try {
|
|
146
141
|
const router = createClientRouterFromPayload(rscPayload, routes, _basename);
|
|
147
|
-
|
|
142
|
+
result.current = {
|
|
148
143
|
router,
|
|
149
144
|
routes: router.routes || []
|
|
150
145
|
};
|
|
146
|
+
return result.current;
|
|
151
147
|
} catch (e) {
|
|
152
148
|
console.error('Failed to create router from RSC payload:', e);
|
|
153
149
|
}
|
|
@@ -196,16 +192,11 @@ function useRouterCreation(props, options) {
|
|
|
196
192
|
};
|
|
197
193
|
return originSubscribe(wrappedListener);
|
|
198
194
|
};
|
|
199
|
-
|
|
195
|
+
result.current = {
|
|
200
196
|
router,
|
|
201
197
|
routes: modifiedRoutes
|
|
202
198
|
};
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
props,
|
|
206
|
-
_basename,
|
|
207
|
-
hydrationData,
|
|
208
|
-
getBlockNavState
|
|
209
|
-
]);
|
|
199
|
+
}
|
|
200
|
+
return result.current;
|
|
210
201
|
}
|
|
211
202
|
export { beforeCreateRouter, finalRouteConfig, modifyRoutes, routerPlugin };
|
|
@@ -124,7 +124,7 @@ const routerPlugin = (userConfig = {})=>({
|
|
|
124
124
|
}) : /*#__PURE__*/ jsx(RSCStaticRouter, {
|
|
125
125
|
basename: basename
|
|
126
126
|
});
|
|
127
|
-
{
|
|
127
|
+
else {
|
|
128
128
|
const { nonce, mode, useJsonScript } = context.ssrContext;
|
|
129
129
|
const remixRouter = createStaticRouter(routes, routerContext);
|
|
130
130
|
const routerWrapper = /*#__PURE__*/ jsxs(Fragment, {
|
package/package.json
CHANGED
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"modern",
|
|
18
18
|
"modern.js"
|
|
19
19
|
],
|
|
20
|
-
"version": "3.9.0-ultramodern.
|
|
20
|
+
"version": "3.9.0-ultramodern.13",
|
|
21
21
|
"engines": {
|
|
22
22
|
"node": ">=20"
|
|
23
23
|
},
|
|
@@ -217,48 +217,48 @@
|
|
|
217
217
|
"dependencies": {
|
|
218
218
|
"@loadable/component": "5.16.7",
|
|
219
219
|
"@loadable/server": "5.16.7",
|
|
220
|
-
"@modern-js/plugin": "npm:@bleedingdev/modern-js-plugin@3.9.0-ultramodern.
|
|
221
|
-
"@modern-js/plugin-data-loader": "npm:@bleedingdev/modern-js-plugin-data-loader@3.9.0-ultramodern.
|
|
222
|
-
"@modern-js/render": "npm:@bleedingdev/modern-js-render@3.9.0-ultramodern.
|
|
223
|
-
"@modern-js/runtime-extensions": "npm:@bleedingdev/modern-js-runtime-extensions@3.9.0-ultramodern.
|
|
224
|
-
"@modern-js/runtime-utils": "npm:@bleedingdev/modern-js-runtime-utils@3.9.0-ultramodern.
|
|
225
|
-
"@modern-js/server-core": "npm:@bleedingdev/modern-js-server-core@3.9.0-ultramodern.
|
|
226
|
-
"@modern-js/types": "npm:@bleedingdev/modern-js-types@3.9.0-ultramodern.
|
|
227
|
-
"@modern-js/utils": "npm:@bleedingdev/modern-js-utils@3.9.0-ultramodern.
|
|
220
|
+
"@modern-js/plugin": "npm:@bleedingdev/modern-js-plugin@3.9.0-ultramodern.13",
|
|
221
|
+
"@modern-js/plugin-data-loader": "npm:@bleedingdev/modern-js-plugin-data-loader@3.9.0-ultramodern.13",
|
|
222
|
+
"@modern-js/render": "npm:@bleedingdev/modern-js-render@3.9.0-ultramodern.13",
|
|
223
|
+
"@modern-js/runtime-extensions": "npm:@bleedingdev/modern-js-runtime-extensions@3.9.0-ultramodern.13",
|
|
224
|
+
"@modern-js/runtime-utils": "npm:@bleedingdev/modern-js-runtime-utils@3.9.0-ultramodern.13",
|
|
225
|
+
"@modern-js/server-core": "npm:@bleedingdev/modern-js-server-core@3.9.0-ultramodern.13",
|
|
226
|
+
"@modern-js/types": "npm:@bleedingdev/modern-js-types@3.9.0-ultramodern.13",
|
|
227
|
+
"@modern-js/utils": "npm:@bleedingdev/modern-js-utils@3.9.0-ultramodern.13",
|
|
228
228
|
"@swc/core": "1.16.2",
|
|
229
229
|
"@swc/helpers": "^0.5.23",
|
|
230
230
|
"@swc/plugin-loadable-components": "^13.0.0",
|
|
231
231
|
"@types/loadable__component": "^5.13.10",
|
|
232
232
|
"@types/react-helmet": "^6.1.11",
|
|
233
233
|
"cookie": "2.0.1",
|
|
234
|
-
"entities": "^8.
|
|
234
|
+
"entities": "^8.1.0",
|
|
235
235
|
"es-module-lexer": "^2.3.2",
|
|
236
236
|
"esbuild": "^0.28.2",
|
|
237
237
|
"invariant": "^2.2.4",
|
|
238
238
|
"isbot": "5.2.2",
|
|
239
239
|
"react-helmet": "^6.1.0",
|
|
240
240
|
"react-helmet-async": "3.0.0",
|
|
241
|
-
"react-is": "^19.
|
|
241
|
+
"react-is": "^19.3.0"
|
|
242
242
|
},
|
|
243
243
|
"peerDependencies": {
|
|
244
244
|
"react": "^19.2.8",
|
|
245
245
|
"react-dom": "^19.2.8"
|
|
246
246
|
},
|
|
247
247
|
"devDependencies": {
|
|
248
|
-
"@modern-js/app-tools": "npm:@bleedingdev/modern-js-app-tools@3.9.0-ultramodern.
|
|
248
|
+
"@modern-js/app-tools": "npm:@bleedingdev/modern-js-app-tools@3.9.0-ultramodern.13",
|
|
249
249
|
"@remix-run/web-fetch": "^4.4.2",
|
|
250
|
-
"@rsbuild/core": "2.2.
|
|
251
|
-
"@rslib/core": "1.0.
|
|
250
|
+
"@rsbuild/core": "2.2.9",
|
|
251
|
+
"@rslib/core": "1.0.2",
|
|
252
252
|
"@scripts/rstest-config": "2.66.0",
|
|
253
|
-
"@testing-library/dom": "^10.4.
|
|
253
|
+
"@testing-library/dom": "^10.4.2",
|
|
254
254
|
"@testing-library/react": "^16.3.3",
|
|
255
255
|
"@types/cookie": "0.6.0",
|
|
256
256
|
"@types/invariant": "^2.2.37",
|
|
257
257
|
"@types/loadable__server": "5.12.11",
|
|
258
|
-
"@types/node": "^26.
|
|
258
|
+
"@types/node": "^26.6.2",
|
|
259
259
|
"@typescript/native-preview": "7.0.0-dev.20260707.2",
|
|
260
|
-
"react": "^19.
|
|
261
|
-
"react-dom": "^19.
|
|
260
|
+
"react": "^19.3.0",
|
|
261
|
+
"react-dom": "^19.3.0",
|
|
262
262
|
"ts-node": "^10.9.2",
|
|
263
263
|
"typescript": "^7.0.2"
|
|
264
264
|
},
|