feat(lstv2 move): moved lstv2 into this app to keep them combined and easier to maintain
This commit is contained in:
40
lstV2/frontend/vite.config.ts
Normal file
40
lstV2/frontend/vite.config.ts
Normal file
@@ -0,0 +1,40 @@
|
||||
import { defineConfig } from "vite";
|
||||
import react from "@vitejs/plugin-react-swc";
|
||||
import tailwindcss from "@tailwindcss/vite";
|
||||
import { TanStackRouterVite } from "@tanstack/router-plugin/vite";
|
||||
import path from "path";
|
||||
|
||||
import dotenv from "dotenv";
|
||||
import { fileURLToPath } from "url";
|
||||
dotenv.config({
|
||||
path: path.resolve(path.dirname(fileURLToPath(import.meta.url)), "../.env"),
|
||||
});
|
||||
|
||||
// https://vite.dev/config/
|
||||
export default defineConfig({
|
||||
plugins: [
|
||||
react(),
|
||||
tailwindcss(),
|
||||
TanStackRouterVite({ target: "react", autoCodeSplitting: true }),
|
||||
],
|
||||
// base: "/lst", // this is whats showing in the ssl version and we need this to work on both versions that also have a port on them.
|
||||
resolve: {
|
||||
alias: {
|
||||
"@": path.resolve(__dirname, "./src"),
|
||||
},
|
||||
},
|
||||
server: {
|
||||
proxy: {
|
||||
"/api": {
|
||||
target: `http://localhost:${Number(process.env.VITE_SERVER_PORT || 4400)}`,
|
||||
changeOrigin: true,
|
||||
secure: false,
|
||||
},
|
||||
"/ocme": {
|
||||
target: `http://localhost:${Number(process.env.VITE_SERVER_PORT || 4400)}`,
|
||||
changeOrigin: true,
|
||||
secure: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user