mirror of
https://github.com/luckfox-eng29/kvm.git
synced 2026-05-28 09:01:22 +02:00
Update App version to 0.1.1
Signed-off-by: luckfox-eng29 <eng29@luckfox.com>
This commit is contained in:
@@ -3,7 +3,7 @@ import react from "@vitejs/plugin-react-swc";
|
||||
import tailwindcss from "@tailwindcss/vite";
|
||||
import tsconfigPaths from "vite-tsconfig-paths";
|
||||
import basicSsl from "@vitejs/plugin-basic-ssl";
|
||||
|
||||
import svgr from 'vite-plugin-svgr';
|
||||
declare const process: {
|
||||
env: {
|
||||
KVM_PROXY_URL: string;
|
||||
@@ -20,7 +20,12 @@ export default defineConfig(({ mode, command }) => {
|
||||
const plugins = [
|
||||
tailwindcss(),
|
||||
tsconfigPaths(),
|
||||
react()
|
||||
react(),
|
||||
svgr({
|
||||
svgrOptions: {
|
||||
icon: true,
|
||||
},
|
||||
}),
|
||||
];
|
||||
if (useSSL) {
|
||||
plugins.push(basicSsl());
|
||||
@@ -28,7 +33,26 @@ export default defineConfig(({ mode, command }) => {
|
||||
|
||||
return {
|
||||
plugins,
|
||||
build: { outDir: isCloud ? "dist" : "../static" },
|
||||
build: {
|
||||
outDir: isCloud ? "dist" : "../static",
|
||||
chunkSizeWarningLimit: 4096,
|
||||
rollupOptions: {
|
||||
onwarn(warning, warn) {
|
||||
const msg = typeof warning === "string" ? warning : warning.message;
|
||||
if (
|
||||
warning &&
|
||||
typeof warning === "object" &&
|
||||
warning.code === "PLUGIN_WARNING" &&
|
||||
// Vite's resolve plugin may log this when a dependency references Node built-ins (e.g. "stream")
|
||||
msg.includes('has been externalized for browser compatibility') &&
|
||||
msg.includes('Module "stream"')
|
||||
) {
|
||||
return;
|
||||
}
|
||||
warn(warning);
|
||||
},
|
||||
},
|
||||
},
|
||||
server: {
|
||||
host: "0.0.0.0",
|
||||
https: useSSL,
|
||||
|
||||
Reference in New Issue
Block a user