nile/vite.config.js
Dunemask d24f39bff4
Some checks failed
Deploy Edge / deploy-edge (push) Failing after 2s
S3 Repo Backup / s3-repo-backup (push) Failing after 3s
[FEATURE] Updated Stylings
2024-08-09 20:17:57 -06:00

31 lines
769 B
JavaScript

import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
import { analyzer } from "vite-bundle-analyzer";
import path from "node:path";
const plugins = [react()];
if (process.env.USE_ANALYZER === "true") plugins.push(analyzer());
export default () => {
return defineConfig({
plugins,
server: {
port: process.env.VITE_DEV_PORT ?? 5173,
host: "0.0.0.0",
hmr: {
protocol: process.env.VITE_DEV_PROTOCOL ?? "wss",
},
},
build: {
outDir: "./dist",
},
resolve: {
alias: {
"@": path.resolve("./src"),
"@components": path.resolve("./src/components"),
"@images": path.resolve("./src/images"),
"@css": path.resolve("./src/css"),
},
},
});
};