persona-community-5/apps/community-ui/vite.config.ts
rdev-worker b4eded185f build: Add community-ui React app with persona grid, OTP login, and detail pages
New React app at apps/community-ui (port 3002) using shared packages.
- OTP-only login flow via @persona-community-5/auth
- Responsive persona card grid with generating state overlays
- Create persona panel (Sheet sliding from right) with description, gender, name
- Detail page with banner header, avatar, image gallery with lightbox, video players
- Real-time updates via useEventChannel subscribed to channel:personas

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 08:22:12 +00:00

31 lines
753 B
TypeScript

import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
export default defineConfig({
plugins: [react()],
server: {
port: 3002,
proxy: {
'/api/persona-api/events': {
target: 'http://localhost:8001',
changeOrigin: true,
configure: (proxy) => {
proxy.on('proxyRes', (proxyRes) => {
if (proxyRes.headers['content-type']?.includes('text/event-stream')) {
proxyRes.headers['cache-control'] = 'no-cache';
proxyRes.headers['x-accel-buffering'] = 'no';
}
});
},
},
'/api': {
target: 'http://localhost:8001',
changeOrigin: true,
},
},
},
preview: {
port: 3002,
},
});