feat: 新增 node-frontend-vite5 示例(Vite 5 + Vue 3,Tengine 托管)

This commit is contained in:
2026-11-15 11:53:02 +08:00
parent 92a57d99a0
commit 90c3334368
15 changed files with 432 additions and 0 deletions
@@ -0,0 +1,23 @@
import { defineConfig } from 'vite';
import vue from '@vitejs/plugin-vue';
// 纯静态前端:产物由 Tengine 托管,base 用相对路径,部署到任意子路径都能跑
export default defineConfig({
plugins: [vue()],
base: './',
server: {
host: '0.0.0.0',
port: 5473,
},
build: {
outDir: 'dist',
sourcemap: false,
rollupOptions: {
output: {
manualChunks: {
vue: ['vue', 'vue-router'],
},
},
},
},
});