frontAnswerer/vite.config.widget.ts

31 lines
796 B
TypeScript
Raw Normal View History

2024-05-31 16:41:18 +00:00
import react from "@vitejs/plugin-react";
import { defineConfig } from "vite";
import { alias } from "./vite.config";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
resolve: {
alias,
},
build: {
2025-07-01 13:49:30 +00:00
minify: false, // Отключает минификацию
sourcemap: true, // Включает sourcemaps для отладки
2024-05-31 16:41:18 +00:00
copyPublicDir: false,
rollupOptions: {
input: "src/widget.tsx",
preserveEntrySignatures: "allow-extension",
output: {
manualChunks: undefined,
entryFileNames: "[name].js",
chunkFileNames: "[name].js",
assetFileNames: "[name].[ext]",
},
},
outDir: "widget",
},
define: {
"process.env": process.env,
},
});