A vite plugin support setup React Router by JSON config file.
github.com/jtsang4/vite-plugin-react-routes
jtsang4/vite-plugin-react-routes