2026-07-04 22:51:52 +08:00
|
|
|
import { resolve } from "node:path"
|
2026-07-11 21:50:34 +08:00
|
|
|
import { fileURLToPath } from "node:url"
|
2026-07-04 22:51:52 +08:00
|
|
|
import vue from "@vitejs/plugin-vue"
|
|
|
|
|
import { defineConfig } from "vite"
|
|
|
|
|
|
2026-07-11 21:50:34 +08:00
|
|
|
const rootDir = fileURLToPath(new URL(".", import.meta.url))
|
|
|
|
|
|
2026-07-04 22:51:52 +08:00
|
|
|
export default defineConfig({
|
|
|
|
|
plugins: [vue()],
|
2026-07-11 21:50:34 +08:00
|
|
|
root: rootDir,
|
2026-07-04 22:51:52 +08:00
|
|
|
base: "/api/v1/plugins/extensions/astrbot_plugin_imagestudio/web/",
|
|
|
|
|
build: {
|
2026-07-11 21:50:34 +08:00
|
|
|
outDir: resolve(rootDir, "../../web"),
|
2026-07-04 22:51:52 +08:00
|
|
|
emptyOutDir: true,
|
|
|
|
|
},
|
|
|
|
|
})
|