19 lines
476 B
TypeScript
19 lines
476 B
TypeScript
import { defineConfig } from "vite";
|
|
import react from "@vitejs/plugin-react";
|
|
|
|
export default defineConfig({
|
|
plugins: [react()],
|
|
base: process.env.VITE_APP_BASE_PATH ?? "/",
|
|
server: {
|
|
host: "0.0.0.0",
|
|
port: Number(process.env.ADMIN_PORT ?? 3000),
|
|
proxy: {
|
|
"/api": {
|
|
target: process.env.VITE_DEV_API_TARGET ?? "http://localhost:3001",
|
|
rewrite: (path) => path.replace(/^\/api/, ""),
|
|
},
|
|
},
|
|
},
|
|
build: { outDir: "dist" },
|
|
});
|