mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-11-14 17:44:32 -08:00
e773e454e9
Some checks failed
Auto Test / armv7-simple-test (18, ARMv7) (push) Has been cancelled
Auto Test / armv7-simple-test (20, ARMv7) (push) Has been cancelled
Auto Test / check-linters (push) Has been cancelled
Auto Test / e2e-test (push) Has been cancelled
CodeQL / Analyze (go) (push) Has been cancelled
CodeQL / Analyze (javascript-typescript) (push) Has been cancelled
Merge Conflict Labeler / Labeling (push) Has been cancelled
json-yaml-validate / json-yaml-validate (push) Has been cancelled
Auto Test / auto-test (18, ARM64) (push) Has been cancelled
Auto Test / auto-test (18, macos-latest) (push) Has been cancelled
Auto Test / auto-test (18, ubuntu-latest) (push) Has been cancelled
Auto Test / auto-test (18, windows-latest) (push) Has been cancelled
Auto Test / auto-test (20, ARM64) (push) Has been cancelled
Auto Test / auto-test (20, macos-latest) (push) Has been cancelled
Auto Test / auto-test (20, ubuntu-latest) (push) Has been cancelled
Auto Test / auto-test (20, windows-latest) (push) Has been cancelled
56 lines
1.4 KiB
JavaScript
56 lines
1.4 KiB
JavaScript
import vue from "@vitejs/plugin-vue";
|
|
import { defineConfig } from "vite";
|
|
import visualizer from "rollup-plugin-visualizer";
|
|
import viteCompression from "vite-plugin-compression";
|
|
import VueDevTools from "vite-plugin-vue-devtools";
|
|
|
|
const postCssScss = require("postcss-scss");
|
|
const postcssRTLCSS = require("postcss-rtlcss");
|
|
|
|
const viteCompressionFilter = /\.(js|mjs|json|css|html|svg)$/i;
|
|
|
|
// https://vitejs.dev/config/
|
|
export default defineConfig({
|
|
server: {
|
|
port: 3000,
|
|
},
|
|
define: {
|
|
"FRONTEND_VERSION": JSON.stringify(process.env.npm_package_version),
|
|
"process.env": {},
|
|
},
|
|
plugins: [
|
|
vue(),
|
|
visualizer({
|
|
filename: "tmp/dist-stats.html"
|
|
}),
|
|
viteCompression({
|
|
algorithm: "gzip",
|
|
filter: viteCompressionFilter,
|
|
}),
|
|
viteCompression({
|
|
algorithm: "brotliCompress",
|
|
filter: viteCompressionFilter,
|
|
}),
|
|
VueDevTools(),
|
|
],
|
|
css: {
|
|
postcss: {
|
|
"parser": postCssScss,
|
|
"map": false,
|
|
"plugins": [ postcssRTLCSS ]
|
|
}
|
|
},
|
|
build: {
|
|
commonjsOptions: {
|
|
include: [ /.js$/ ],
|
|
},
|
|
rollupOptions: {
|
|
output: {
|
|
manualChunks(id, { getModuleInfo, getModuleIds }) {
|
|
|
|
}
|
|
}
|
|
},
|
|
}
|
|
});
|