-
Build the project locally first to ensure no errors:
npm run build
-
Push your code to GitHub (if not already done)
-
Deploy to Vercel:
- Go to vercel.com
- Import your GitHub repository
- Vercel will automatically detect it's a Vite project
-
Environment Variables:
- In Vercel dashboard, go to Settings > Environment Variables
- Add these variables:
VITE_BASE_URL=https://platform-404.onrender.com/VITE_PINATA_JWT=your_jwt_token
-
Deploy Settings:
- Build Command:
npm run build - Output Directory:
dist - Install Command:
npm install
- Build Command:
If you still see a blank page:
-
Check Vercel Function Logs:
- Go to your Vercel dashboard
- Click on your deployment
- Check the "Functions" tab for any errors
-
Check Browser Console:
- Open browser developer tools (F12)
- Look for JavaScript errors in the Console tab
-
Check Network Tab:
- See if all assets are loading properly
- Look for 404 errors on CSS/JS files
-
Verify Environment Variables:
- Make sure all VITE_ prefixed variables are set in Vercel
- Blank page: Usually caused by JavaScript errors or missing environment variables
- 404 on refresh: Fixed by the rewrites in vercel.json
- Assets not loading: Check if public folder files are being served correctly
vercel.json- Updated to modern Vercel configurationvite.config.js- Added proper build configuration.env.production- Production environment variables.vercelignore- Exclude unnecessary files from deploymentErrorBoundary.jsx- Catch runtime errorsmain.jsx- Added error boundary wrapper