We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 873c767 commit d16ec89Copy full SHA for d16ec89
packages/react-router/lib/dom/ssr/single-fetch.tsx
@@ -286,14 +286,7 @@ export function addRevalidationParam(
286
export function singleFetchUrl(reqUrl: URL | string) {
287
let url =
288
typeof reqUrl === "string"
289
- ? new URL(
290
- reqUrl,
291
- typeof window === "undefined"
292
- ? // TODO: Trace usage of singleFetchUrl and make sure we don't use it anywhere
293
- // this will make it to a network call.
294
- "server://singlefetch/"
295
- : window.location.origin
296
- )
+ ? new URL(reqUrl, window.location.origin)
297
: reqUrl;
298
url.pathname = `${url.pathname === "/" ? "_root" : url.pathname}.data`;
299
return url;
0 commit comments