From bc35b2d67e9d4cbb27e98656126aa1208bf9e3b3 Mon Sep 17 00:00:00 2001 From: Alessandro-pang Date: Sun, 21 Jul 2024 15:57:43 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E4=BF=AE=E5=A4=8D=20github=20pages=20?= =?UTF-8?q?=E5=8F=91=E5=B8=83=E5=90=8E404=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- demos/vue3-demo/vite.config.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/demos/vue3-demo/vite.config.ts b/demos/vue3-demo/vite.config.ts index 05c1740..88c87a5 100644 --- a/demos/vue3-demo/vite.config.ts +++ b/demos/vue3-demo/vite.config.ts @@ -2,6 +2,10 @@ import { defineConfig } from 'vite' import vue from '@vitejs/plugin-vue' // https://vitejs.dev/config/ -export default defineConfig({ - plugins: [vue()], +export default defineConfig((conf) => { + const isProd = conf.mode === 'production'; + return { + base: isProd ? '/vue-print-next/' :'/', + plugins: [vue()], + } })