foxnouns/frontend/vite.config.ts
2024-03-26 22:10:04 +01:00

23 lines
470 B
TypeScript

import { sveltekit } from "@sveltejs/kit/vite";
import { defineConfig } from "vite";
export default defineConfig({
plugins: [sveltekit()],
server: {
host: "127.0.0.1",
proxy: {
"/api": {
target: "http://localhost:5000",
changeOrigin: true,
},
"/media": {
target: "http://localhost:9000",
changeOrigin: true,
rewrite: (path) => path.replace(/^\/media/, "/pronouns.cc"),
},
},
},
ssr: {
noExternal: ["@popperjs/core"],
},
});