FrostByte/client-solid/vite.config.ts

23 lines
507 B
TypeScript
Raw Normal View History

2023-11-22 15:31:58 +01:00
import { defineConfig } from "vite";
import solid from "vite-plugin-solid";
2023-10-19 02:42:37 +02:00
// https://vitejs.dev/config/
export default defineConfig({
// build: {
// outDir: '../server/public' // Override default outDir('dist')
// },
2024-12-26 13:02:46 +01:00
plugins: [solid()],
2023-10-19 02:42:37 +02:00
server: {
port: 3000,
open: true,
proxy: {
2023-11-22 15:31:58 +01:00
"/api": {
target: "http://localhost:8080/api",
2023-10-19 02:42:37 +02:00
changeOrigin: true,
secure: false,
2023-11-22 15:31:58 +01:00
rewrite: (path): string => path.replace(/^\/api/, ""),
},
},
},
});