From 47ce4b4ddf0720782dffcd70e44e8f788fc552f9 Mon Sep 17 00:00:00 2001 From: Lilith Date: Tue, 20 Jan 2026 22:05:16 -0800 Subject: [PATCH] =?UTF-8?q?chore(fontend-admin):=20=F0=9F=94=A7=20Update?= =?UTF-8?q?=20Vite=20configuration=20for=20build=20optimizations?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- features/platform-admin/frontend-admin/vite.config.ts | 6 ++++-- features/seo/frontend-admin/vite.config.ts | 8 ++++---- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/features/platform-admin/frontend-admin/vite.config.ts b/features/platform-admin/frontend-admin/vite.config.ts index e3f70978e..0a8733c68 100755 --- a/features/platform-admin/frontend-admin/vite.config.ts +++ b/features/platform-admin/frontend-admin/vite.config.ts @@ -102,8 +102,10 @@ export default defineConfig({ }, server: { port: devPort, - // Allow Docker service hostname for E2E testing (Vite 6+ blocks unknown hosts by default) - allowedHosts: ['localhost', '127.0.0.1', 'platform-admin'], + // Bind to all interfaces (IPv4 + IPv6) so Docker's host.docker.internal can reach it + host: '0.0.0.0', + // Allow Docker service hostname and local dev domains (Vite 6+ blocks unknown hosts by default) + allowedHosts: ['localhost', '127.0.0.1', 'platform-admin', 'host.docker.internal', 'admin.atlilith.local'], proxy: { // Feature APIs on dedicated ports '/api/analytics': { diff --git a/features/seo/frontend-admin/vite.config.ts b/features/seo/frontend-admin/vite.config.ts index 3e5f83dc8..2b34c5341 100755 --- a/features/seo/frontend-admin/vite.config.ts +++ b/features/seo/frontend-admin/vite.config.ts @@ -8,10 +8,6 @@ export default defineConfig({ versionPlugin({ appName: 'SEO Admin' }), ], resolve: { - alias: { - // Fix for react-router-dom v7 internal import resolution - 'react-router/dom': 'react-router-dom', - }, // Dedupe packages that use React context to prevent multiple instances dedupe: [ 'react', @@ -22,6 +18,10 @@ export default defineConfig({ 'styled-components', ], }, + // Ensure react-router packages are properly bundled + optimizeDeps: { + include: ['react-router', 'react-router-dom'], + }, base: '/admin/seo/', server: { // Port from infrastructure/ports.yaml: features.seo.frontend-admin