@modern-js/server-core 2.69.6 → 2.70.0
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.
|
@@ -269,7 +269,7 @@ function injectFallbackReasonToHtml({ html, reason, framework }) {
|
|
|
269
269
|
}
|
|
270
270
|
async function csrRender(request, options) {
|
|
271
271
|
const { html, rscClientManifest } = options;
|
|
272
|
-
if (!rscClientManifest || process.env.MODERN_DISABLE_INJECT_RSC_DATA) {
|
|
272
|
+
if (!rscClientManifest || process.env.MODERN_DISABLE_INJECT_RSC_DATA || !options.routeInfo.isRSC) {
|
|
273
273
|
return new Response(html, {
|
|
274
274
|
status: 200,
|
|
275
275
|
headers: new Headers({
|
|
@@ -544,7 +544,7 @@ function _csrRender() {
|
|
|
544
544
|
var html, rscClientManifest;
|
|
545
545
|
return _ts_generator(this, function(_state) {
|
|
546
546
|
html = options.html, rscClientManifest = options.rscClientManifest;
|
|
547
|
-
if (!rscClientManifest || process.env.MODERN_DISABLE_INJECT_RSC_DATA) {
|
|
547
|
+
if (!rscClientManifest || process.env.MODERN_DISABLE_INJECT_RSC_DATA || !options.routeInfo.isRSC) {
|
|
548
548
|
return [
|
|
549
549
|
2,
|
|
550
550
|
new Response(html, {
|
|
@@ -236,7 +236,7 @@ function injectFallbackReasonToHtml({ html, reason, framework }) {
|
|
|
236
236
|
}
|
|
237
237
|
async function csrRender(request, options) {
|
|
238
238
|
const { html, rscClientManifest } = options;
|
|
239
|
-
if (!rscClientManifest || process.env.MODERN_DISABLE_INJECT_RSC_DATA) {
|
|
239
|
+
if (!rscClientManifest || process.env.MODERN_DISABLE_INJECT_RSC_DATA || !options.routeInfo.isRSC) {
|
|
240
240
|
return new Response(html, {
|
|
241
241
|
status: 200,
|
|
242
242
|
headers: new Headers({
|
package/package.json
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"modern",
|
|
16
16
|
"modern.js"
|
|
17
17
|
],
|
|
18
|
-
"version": "2.
|
|
18
|
+
"version": "2.70.0",
|
|
19
19
|
"jsnext:source": "./src/index.ts",
|
|
20
20
|
"types": "./dist/types/index.d.ts",
|
|
21
21
|
"main": "./dist/cjs/index.js",
|
|
@@ -62,10 +62,10 @@
|
|
|
62
62
|
"flatted": "^3.3.3",
|
|
63
63
|
"hono": "^3.12.2",
|
|
64
64
|
"ts-deepmerge": "7.0.2",
|
|
65
|
-
"@modern-js/plugin": "2.
|
|
66
|
-
"@modern-js/runtime-utils": "2.
|
|
67
|
-
"@modern-js/plugin-v2": "2.
|
|
68
|
-
"@modern-js/utils": "2.
|
|
65
|
+
"@modern-js/plugin": "2.70.0",
|
|
66
|
+
"@modern-js/runtime-utils": "2.70.0",
|
|
67
|
+
"@modern-js/plugin-v2": "2.70.0",
|
|
68
|
+
"@modern-js/utils": "2.70.0"
|
|
69
69
|
},
|
|
70
70
|
"devDependencies": {
|
|
71
71
|
"@types/cloneable-readable": "^2.0.3",
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
"jest": "^29",
|
|
77
77
|
"ts-jest": "^29.1.0",
|
|
78
78
|
"typescript": "^5",
|
|
79
|
-
"@modern-js/types": "2.
|
|
79
|
+
"@modern-js/types": "2.70.0",
|
|
80
80
|
"@scripts/build": "2.66.0",
|
|
81
81
|
"@scripts/jest-config": "2.66.0"
|
|
82
82
|
},
|