import tailwindcss from "@tailwindcss/vite"
import { sveltekit } from "@sveltejs/kit/vite"
import { defineConfig } from "vite"

export default defineConfig({
    plugins: [tailwindcss(), sveltekit()],
    server: {
        proxy: {
            "/api": {
                target: "http://backend:5000",
                changeOrigin: false,
                secure: false,
            },
            "/ws": {
                target: "http://backend:5000",
                changeOrigin: false,
                secure: false,
                ws: true,
            },
        },
    },
})
