24 lines
518 B
TypeScript
24 lines
518 B
TypeScript
// vite.config.content.ts
|
|
import { defineConfig } from "vite";
|
|
import path from "path";
|
|
|
|
export default defineConfig({
|
|
resolve: {
|
|
alias: {
|
|
"@": path.resolve(__dirname, "./src"),
|
|
},
|
|
},
|
|
build: {
|
|
outDir: "dist-content",
|
|
emptyOutDir: false, // giữ dist gốc
|
|
rollupOptions: {
|
|
input: path.resolve(__dirname, "src/content/content.tsx"),
|
|
output: {
|
|
entryFileNames: "content/content.js",
|
|
format: "iife",
|
|
inlineDynamicImports: true,
|
|
},
|
|
},
|
|
},
|
|
});
|