mnfst 0.5.44 → 0.5.45
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/manifest.router.js +5 -1
- package/package.json +1 -1
package/dist/manifest.router.js
CHANGED
|
@@ -166,7 +166,11 @@ let isInternalNavigation = false;
|
|
|
166
166
|
function isPrerenderedStaticBuild() {
|
|
167
167
|
// When prerendered HTML is served as static pages, prefer normal browser navigation (MPA)
|
|
168
168
|
// so each URL loads its own prerendered HTML rather than SPA toggling.
|
|
169
|
-
|
|
169
|
+
const prerendered = document.querySelector('meta[name="manifest:prerendered"]');
|
|
170
|
+
const val = (prerendered?.getAttribute('content') || '').trim().toLowerCase();
|
|
171
|
+
if (prerendered && val !== '0' && val !== 'false') return true;
|
|
172
|
+
// Backstop: prerender writes this per-page depth marker.
|
|
173
|
+
return !!document.querySelector('meta[name="manifest:router-base-depth"]');
|
|
170
174
|
}
|
|
171
175
|
|
|
172
176
|
function getBasePath() {
|