Initial Robot U site prototype
This commit is contained in:
commit
fe19f200d7
27 changed files with 3677 additions and 0 deletions
22
frontend/vite.config.ts
Normal file
22
frontend/vite.config.ts
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
import { defineConfig, loadEnv } from "vite";
|
||||
import preact from "@preact/preset-vite";
|
||||
|
||||
export default defineConfig(({ mode }) => {
|
||||
const env = loadEnv(mode, process.cwd(), "");
|
||||
const backendUrl = env.VITE_BACKEND_URL || "http://localhost:8000";
|
||||
|
||||
return {
|
||||
plugins: [preact()],
|
||||
server: {
|
||||
proxy: {
|
||||
"/api": backendUrl,
|
||||
"/health": backendUrl,
|
||||
},
|
||||
},
|
||||
build: {
|
||||
outDir: "dist",
|
||||
emptyOutDir: true,
|
||||
},
|
||||
};
|
||||
});
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue