resistants/vite.config.ts

23 lines
599 B
TypeScript

import react from "@vitejs/plugin-react-swc";
import { defineConfig } from "vite";
import { imagetools } from "vite-imagetools";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react(), imagetools()],
// Resistants module is deployed in framagit under /resistants
base: "/resistants",
build: {
rollupOptions: {
output: {
entryFileNames: "resistants.js",
assetFileNames: ({ name }) =>
name && name.indexOf(".css") > 0
? "resistants.css"
: "assets/[name].[ext]",
},
},
outDir: "public",
},
});