Files
v10/examples/html-demo/vite.config.mts
T
370762f500 feat(examples): configure separate default ports for React and HTML demos
- Set React demo to use port 5173 (Vite's default)
- Set HTML demo to use port 5174 to avoid conflicts
- Enable strictPort: false to allow automatic fallback to next available port
- Allow simultaneous development of both React and HTML demos
- Maintain existing development workflow while preventing port conflicts

This enables developers to run `npm run dev:react` and `npm run dev:html`
concurrently without manual port management.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-08 17:29:12 -07:00

13 lines
299 B
TypeScript

import { defineConfig } from 'vite';
import { fileURLToPath } from 'url';
const __dirname = fileURLToPath(new URL('.', import.meta.url));
export default defineConfig({
root: __dirname,
server: {
port: 5174,
strictPort: false, // Allow Vite to try other ports if 5174 is taken
},
});