Skip to content

Commit

Permalink
feat: 更新 Vite 配置
Browse files Browse the repository at this point in the history
  • Loading branch information
phillychi3 committed Dec 27, 2024
1 parent 778f2d4 commit 46a104d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion frontend/web/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@ export default defineConfig({
plugins: [vidstack(), sveltekit()],
server: {
proxy: {
'/api': 'http://localhost:8000'
'/api': {
target: 'http://localhost:3000',
changeOrigin: true,
rewrite: (path) => path.replace(/^\/api/, '')
}
}
}
})

0 comments on commit 46a104d

Please sign in to comment.