You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the new Remix 2.13.1 with the Single Fetch feature enabled, Vercel does not recognize data loader calls during page navigation when using optional parameters. In the screenshot, you can see an example of this issue. The route has an optional parameter lang. In the first call, the en is not present at the beginning of the URL path, and it returns a status 200 with the correct response.
In the second call, the URL path includes a language, such as nl. This results in a 404 status code, and the page content displayed is from Vercel's default 404 page.
Live demo instructions:
In the live demo, you can see two navigation buttons at the top left: one for the home page and another for a subpage /brands. On the right, there is a simple language selector that also redirects to the homepage for the selected language. English redirects to '/' and Dutch redirects to '/nl'. There appear to be no issues with navigation when using optional parameters on the index page. However, when switching between the home page and the brands page, an issue happens when you are on /nl.
This issue only occurs when clicking the links on the page; it works fine when you navigate directly to the URL.
In the new Remix 2.13.1 with the Single Fetch feature enabled, Vercel does not recognize data loader calls during page navigation when using optional parameters. In the screenshot, you can see an example of this issue. The route has an optional parameter lang. In the first call, the en is not present at the beginning of the URL path, and it returns a status 200 with the correct response.
In the second call, the URL path includes a language, such as nl. This results in a 404 status code, and the page content displayed is from Vercel's default 404 page.
Live demo instructions:
In the live demo, you can see two navigation buttons at the top left: one for the home page and another for a subpage /brands. On the right, there is a simple language selector that also redirects to the homepage for the selected language. English redirects to '/' and Dutch redirects to '/nl'. There appear to be no issues with navigation when using optional parameters on the index page. However, when switching between the home page and the brands page, an issue happens when you are on /nl.
This issue only occurs when clicking the links on the page; it works fine when you navigate directly to the URL.
Repo:
https://github.com/joeykamsteeg/vercel-single-fetch-optional-route-issue
Live Demo:
https://vercel-single-fetch-optional-route-issue.vercel.app
The text was updated successfully, but these errors were encountered: