import reactRefresh from "@vitejs/plugin-react-refresh";
import dotenv from "dotenv";

import { defineConfig } from "vite";

dotenv.config();

// eslint-disable-next-line import/no-default-export
export default defineConfig({
  base: "./",
  plugins: [reactRefresh()],
  server: {
    host: true,
    port: 1337,
  },
  optimizeDeps: {
    exclude: ["./webflow"],
  },
  define: {
    "process.env": {
      ...process.env,
    },
  },
  resolve: {
    alias: {
      "~bootstrap": "bootstrap",
    },
  },
  build: {
    outDir: "public",
    sourcemap: true,
    rollupOptions: {},
  },
});
