:paramName doesn't match URL segments containing dot '.' in react app with Vitejs

Viewed 262

:paramName doesn't match URL segments containing dot '.'

I have a route <Route path="/:id" component={Query} /> in my App.js
When I try to navigate to localhost:3000/abc.xyz, the page shows page not found
Note: The project is using vitejs

1 Answers

Add the plugin https://www.npmjs.com/package/vite-plugin-rewrite-all.
To vite.config.js file. And you are all set.

Related