refactor: reorder arguments in web ui

This commit is contained in:
2026-03-22 03:23:09 +02:00
parent d7984c12f0
commit 5e090cebdb
61 changed files with 547 additions and 578 deletions

View File

@@ -4,34 +4,34 @@ import { defineConfig, type Plugin } from "vite";
function rename(oldName: string, newName: string): Plugin {
return {
name: "rename",
enforce: "post",
generateBundle(_, bundle) {
if (bundle[oldName]) {
bundle[oldName].fileName = newName;
}
},
name: "rename",
};
}
export default defineConfig({
plugins: [react(), rename("index.html", "build-status.jinja2")],
base: "/",
resolve: {
tsconfigPaths: true,
},
build: {
chunkSizeWarningLimit: 10000,
emptyOutDir: false,
outDir: path.resolve(__dirname, "../package/share/ahriman/templates"),
rollupOptions: {
rolldownOptions: {
output: {
entryFileNames: "static/[name].js",
chunkFileNames: "static/[name].js",
assetFileNames: "static/[name].[ext]",
chunkFileNames: "static/[name].js",
entryFileNames: "static/[name].js",
},
},
},
plugins: [react(), rename("index.html", "build-status.jinja2")],
resolve: {
tsconfigPaths: true,
},
server: {
proxy: {
"/api": "http://localhost:8080",