I deployed a vite app on vercel , the deployment was successful, but when I visit a particular route it shows 404 Not Found Error
Deployment State

404 "NOT_FOUND" Error on page

I'm using typescript with vite and in tsConfig I have mentioned rootDir: "./src" outDir: "./dist"
so vite makes build on dist folder on root directory as I have shown in screenshot below

I have used this configuration in vercel.json
{ "rewrites": [ { "source": "/(.*)", "destination": "/dist/index.html" } ]}These are my project settings

PS: I'm using react-router-dom for route handling in vite app