Development
Production Build
Learn how to create optimized production builds for your Viber3D game.
Creating a Production Build
npm run build
This command will:
- Compile your TypeScript code
- Bundle all assets
- Optimize for production
- Output static files in
dist/
Testing the Production Build
npm run preview
This serves your built files at http://localhost:4173 by default.
Optimizations
- Code Minification
JavaScript & CSS minified, dead code elimination, tree-shaking. - Asset Optimization
Image compression, font subsetting, static asset fingerprinting. - Performance
Code splitting, lazy loading components, caching headers.
Deployment
After building:
- The
dist/
folder contains everything needed - Deploy to any static hosting service (Netlify, Vercel, etc.)
- No server runtime required