remix-run / react-router

Declarative routing for React

Home Page:https://reactrouter.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Bug]: No route matches URL in production build

harryzcy opened this issue · comments

What version of React Router are you using?

v6.22.3

Steps to Reproduce

I haven't found the exact reason for this. I'm using Vite v5.2.10. The error starts to occur when rollup is updated from v4.14.2 to v4.16.1.

Expected Behavior

The router should work fine.

Actual Behavior

image

Even redirect is not working.

Might be a bug in rollup and is unrelated to react-router. Possibly related: rollup/rollup#5484?

My case is fixed with rollup 4.16.2. rollup/rollup#5484 is a different issue.
Related: #11480