/// import { defineConfig } from 'vite' import react from '@vitejs/plugin-react' import tailwindcss from '@tailwindcss/vite' import wasm from 'vite-plugin-wasm' import topLevelAwait from 'vite-plugin-top-level-await' import path from 'path' export default defineConfig({ plugins: [react(), tailwindcss(), wasm(), topLevelAwait()], test: { globals: true, environment: 'jsdom', setupFiles: ['./src/__tests__/setup.ts'], css: true, }, resolve: { alias: { 'nkode-client-wasm': path.resolve(__dirname, 'pkg'), }, }, server: { proxy: { '/v1': { target: 'http://localhost:3000', changeOrigin: true, }, }, fs: { allow: ['..'], }, }, optimizeDeps: { exclude: ['nkode-client-wasm'], }, })