diff --git a/vite.config.ts b/vite.config.ts index 52c04f3..f7831dd 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -8,7 +8,14 @@ export default defineConfig({ // Pinned (rather than Vite's default floating port) so local Supabase // Auth's redirect allow-list (supabase/config.toml) stays valid instead of // silently breaking if 5173 happens to be busy and Vite picks another one. + // Host is explicit too: Vite's default "localhost" resolves to the IPv6 + // loopback (::1) on this machine, so it never actually listens on + // 127.0.0.1 — but that's exactly the address Supabase Auth's email + // confirmation links redirect to (config.toml uses 127.0.0.1 throughout, + // matching Supabase's own convention). Binding here to 127.0.0.1 instead + // of leaving it to resolve is what makes those links actually work. server: { + host: '127.0.0.1', port: 5173, strictPort: true, },