@expo/router-server 58.0.17 → 58.0.18
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.
|
@@ -159,7 +159,7 @@ function resetReactNavigationContexts() {
|
|
|
159
159
|
function prepareRenderContext(location, options) {
|
|
160
160
|
const headContext = {};
|
|
161
161
|
const Root = (0, _getRootComponent.getRootComponent)();
|
|
162
|
-
const { pathname, params } = (0, _static().getRouteInfoForMatchedRoute)(options.route, options.params ?? {}, location);
|
|
162
|
+
const { pathname, params, searchParams } = (0, _static().getRouteInfoForMatchedRoute)(options.route, options.params ?? {}, location);
|
|
163
163
|
const { // NOTE: The `element` that's returned adds two extra Views and
|
|
164
164
|
// the seemingly unused `RootTagContext.Provider`.
|
|
165
165
|
element, getStyleElement } = (0, _static().registerStaticRootComponent)(_exporouter().ExpoRoot, {
|
|
@@ -175,7 +175,8 @@ function prepareRenderContext(location, options) {
|
|
|
175
175
|
})
|
|
176
176
|
});
|
|
177
177
|
resetReactNavigationContexts();
|
|
178
|
-
const
|
|
178
|
+
const search = searchParams.toString();
|
|
179
|
+
const loaderKey = options.loader ? options.loader.key + (search ? `?${search}` : '') : null;
|
|
179
180
|
const loadedData = loaderKey ? {
|
|
180
181
|
[loaderKey]: options.loader?.data ?? null
|
|
181
182
|
} : null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["server/renderStreamingContent.tsx"],"sourcesContent":[null],"names":["getStreamingContent","resolveMetadata","debug","createDebug","resetReactNavigationContexts","contexts","globalThis","Map","prepareRenderContext","location","options","headContext","Root","getRootComponent","pathname","params","getRouteInfoForMatchedRoute","route","element","getStyleElement","registerStaticRootComponent","ExpoRoot","context","ctx","wrapper","children","div","id","loaderKey","loader","key","
|
|
1
|
+
{"version":3,"sources":["server/renderStreamingContent.tsx"],"sourcesContent":[null],"names":["getStreamingContent","resolveMetadata","debug","createDebug","resetReactNavigationContexts","contexts","globalThis","Map","prepareRenderContext","location","options","headContext","Root","getRootComponent","pathname","params","searchParams","getRouteInfoForMatchedRoute","route","element","getStyleElement","registerStaticRootComponent","ExpoRoot","context","ctx","wrapper","children","div","id","search","toString","loaderKey","loader","key","loadedData","data","FontResources","descriptors","Font","getServerResourceDescriptors","length","createInjectedFontsAsNodes","withServerContext","headNodes","cssNodes","createInjectedCssAsNodes","normalizeCssAssets","assets","faviconNode","favicon","createFaviconAsNode","undefined","headJsNodes","bodyNodes","bodyJsNodes","createInjectedScriptAsNodes","js","serverDocumentData","metadata","filter","Boolean","isStatic","output","renderErrors","stream","ReactDOMServer","renderToReadableStream","ServerDocument","Head","Provider","InnerRoot","progressiveChunkSize","Number","MAX_SAFE_INTEGER","bootstrapScriptContent","getBootstrapContents","hydrate","signal","request","onError","error","aborted","push","console","allReady","Response","text"],"mappings":"AAAA;;;;;CAKC,GACD,kEAAkE;AAClE,gCAAgC;;;;;;;;;;;;;;;;QAsHVA;eAAAA;;QAwEbC;eAAAA,yBAAe;;;;;;;;;;;iEA5LF;;;;;;;yBACG;;;;;;;yBACL;;;;;;;gEACH;;;;;;;yBACc;;;;;;;yBAKxB;;;;;;;yBAC+D;;;;;;;gEAChC;;;;;;;gEACX;;;;;;kCAEM;uBACL;wBAOrB;0BAsKyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AApKhC,MAAMC,QAAQC,IAAAA,kBAAW,EAAC;AAE1B,SAASC;IACP,iDAAiD;IACjD,0JAA0J;IAE1J,8FAA8F;IAC9F,yJAAyJ;IACzJ,MAAMC,WAAW;IAChBC,UAAkB,CAACD,SAAS,GAAG,IAAIE;AACtC;AAwBA,SAASC,qBAAqBC,QAAa,EAAEC,OAAmC;IAC9E,MAAMC,cAAgC,CAAC;IACvC,MAAMC,OAAOC,IAAAA,kCAAgB;IAC7B,MAAM,EAAEC,QAAQ,EAAEC,MAAM,EAAEC,YAAY,EAAE,GAAGC,IAAAA,qCAA2B,EACpEP,QAAQQ,KAAK,EACbR,QAA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F"}
|
|
@@ -160,7 +160,7 @@ function resetReactNavigationContexts() {
|
|
|
160
160
|
*/ function prepareRenderContext(location, options) {
|
|
161
161
|
const headContext = {};
|
|
162
162
|
const Root = (0, _getRootComponent.getRootComponent)();
|
|
163
|
-
const { pathname, params } = (0, _static().getRouteInfoForMatchedRoute)(options.route, options.params ?? {}, location);
|
|
163
|
+
const { pathname, params, searchParams } = (0, _static().getRouteInfoForMatchedRoute)(options.route, options.params ?? {}, location);
|
|
164
164
|
const { // NOTE: The `element` that's returned adds two extra Views and
|
|
165
165
|
// the seemingly unused `RootTagContext.Provider`.
|
|
166
166
|
element, getStyleElement } = (0, _static().registerStaticRootComponent)(_exporouter().ExpoRoot, {
|
|
@@ -178,7 +178,8 @@ function resetReactNavigationContexts() {
|
|
|
178
178
|
// This MUST be run before `ReactDOMServer.renderToString` to prevent
|
|
179
179
|
// "Warning: Detected multiple renderers concurrently rendering the same context provider. This is currently unsupported."
|
|
180
180
|
resetReactNavigationContexts();
|
|
181
|
-
const
|
|
181
|
+
const search = searchParams.toString();
|
|
182
|
+
const loaderKey = options.loader ? options.loader.key + (search ? `?${search}` : '') : null;
|
|
182
183
|
const loadedData = loaderKey ? {
|
|
183
184
|
[loaderKey]: options.loader?.data ?? null
|
|
184
185
|
} : null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["static/renderStaticContent.tsx"],"sourcesContent":[null],"names":["getBuildTimeServerManifestAsync","getManifest","getStaticContent","getStreamingContent","resolveMetadata","debug","createDebug","resetReactNavigationContexts","contexts","globalThis","Map","prepareRenderContext","location","options","headContext","Root","getRootComponent","pathname","params","getRouteInfoForMatchedRoute","route","element","getStyleElement","registerStaticRootComponent","ExpoRoot","context","ctx","wrapper","children","div","id","loaderKey","loader","key","
|
|
1
|
+
{"version":3,"sources":["static/renderStaticContent.tsx"],"sourcesContent":[null],"names":["getBuildTimeServerManifestAsync","getManifest","getStaticContent","getStreamingContent","resolveMetadata","debug","createDebug","resetReactNavigationContexts","contexts","globalThis","Map","prepareRenderContext","location","options","headContext","Root","getRootComponent","pathname","params","searchParams","getRouteInfoForMatchedRoute","route","element","getStyleElement","registerStaticRootComponent","ExpoRoot","context","ctx","wrapper","children","div","id","search","toString","loaderKey","loader","key","loadedData","data","Font","withServerContext","html","ReactDOMServer","renderToString","Head","Provider","InnerRoot","css","renderToStaticMarkup","output","mixHeadComponentsWithStaticResults","helmet","replace","fonts","getServerResources","length","join","createLoaderDataScriptAsString","injectAssetsIntoHtml","assets","hydrate","headTags","htmlAttributes","bodyAttributes","serializeHelmetToHtml"],"mappings":"AAAA;;;;;CAKC;;;;;;;;;;;;;;;;;;QAmJQA;eAAAA,kDAA+B;;QAAEC;eAAAA,8BAAW;;QArD/BC;eAAAA;;QAoDbC;eAAAA,2CAAmB;;QAAEC;eAAAA,uCAAe;;;;;;;;;;QAjJtC;;iEACe;;;;;;;yBACG;;;;;;;yBACL;;;;;;;gEACH;;;;;;;yBAKV;;;;;;;gEAEW;;;;;;;gEACS;;;;;;uBAEC;sBAKrB;kCAC0B;wCA6HoB;mCACQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA5H7D,MAAMC,QAAQC,IAAAA,kBAAW,EAAC;AAE1B,SAASC;IACP,iDAAiD;IACjD,0JAA0J;IAE1J,8FAA8F;IAC9F,yJAAyJ;IACzJ,MAAMC,WAAW;IAChBC,UAAkB,CAACD,SAAS,GAAG,IAAIE;AACtC;AAiBA;;;CAGC,GACD,SAASC,qBAAqBC,QAAa,EAAEC,OAAgC;IAC3E,MAAMC,cAAgC,CAAC;IACvC,MAAMC,OAAOC,IAAAA,kCAAgB;IAC7B,MAAM,EAAEC,QAAQ,EAAEC,MAAM,EAAEC,YAAY,EAAE,GAAGC,IAAAA,qCAA2B,EACpEP,QAAQQ,KAAK,EACbR,QAAQK,MAAM,IAAI,CAAC,GACnBN;IAGF,MAAM,EACJ,+DAA+D;IAC/D,kDAAkD;IAClDU,OAAO,E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G,OAAO,CAAC,WAAW,GAAGC,MAAMG,IAAI,CAAC,IAAI,OAAO,CAAC;QAC7D,IAAInB,YAAY;YACdY,SAASA,OAAOG,OAAO,CAAC,WAAW,GAAGK,IAAAA,oCAA8B,EAACpB,YAAY,OAAO,CAAC;QAC3F;QAEAY,SAASS,IAAAA,0BAAoB,EAACT,QAAQ;YAAEU,QAAQ9C,QAAQ8C,MAAM;YAAEC,SAAS/C,QAAQ+C,OAAO;QAAC;QAEzF,OAAO,oBAAoBX;IAC7B;AACF;AAEA,SAASC,mCAAmCC,MAAW,EAAEV,IAAY;IACnE,MAAM,EAAEoB,QAAQ,EAAEC,cAAc,EAAEC,cAAc,EAAE,GAAGC,IAAAA,2BAAqB,EAACb;IAE3E,IAAIU,UAAU;QACZpB,OAAOA,KAAKW,OAAO,CAAC,UAAU,CAAC,MAAM,EAAES,UAAU;IACnD;IAEA,aAAa;IACbpB,OAAOA,KAAKW,OAAO,CAAC,UAAU,CAAC,MAAM,EAAEU,eAAe,CAAC,CAAC;IACxDrB,OAAOA,KAAKW,OAAO,CAAC,UAAU,CAAC,MAAM,EAAEW,eAAe,CAAC,CAAC;IAExD,OAAOtB;AACT"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@expo/router-server",
|
|
3
|
-
"version": "58.0.
|
|
3
|
+
"version": "58.0.18",
|
|
4
4
|
"description": "Expo Router is a file-based router for React Native and web applications.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"expo",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@types/react-dom": "^19.1.7",
|
|
39
39
|
"@typescript/vfs": "^1.6.4",
|
|
40
40
|
"expect-type": "^1.3.0",
|
|
41
|
-
"expo-router": "58.0.
|
|
41
|
+
"expo-router": "58.0.27",
|
|
42
42
|
"node-html-parser": "^6.1.5",
|
|
43
43
|
"react-server-dom-webpack": "~19.0.8"
|
|
44
44
|
},
|