fix: 优化打包命令
This commit is contained in:
@@ -1,9 +0,0 @@
|
||||
import fs from "fs";
|
||||
|
||||
const htmlPath = "./dist/index.html"; // 打包后的html文件路径
|
||||
const htmlText = fs.readFileSync(htmlPath, 'utf8');
|
||||
const result = htmlText.replace(/\/log-lottery/g, '.')
|
||||
console.log(result)
|
||||
fs.writeFileSync(htmlPath, result, 'utf8');
|
||||
|
||||
console.log("处理完成");
|
||||
@@ -8,7 +8,7 @@
|
||||
"dev": "vite --host 0.0.0.0",
|
||||
"build": "vue-tsc --noEmit && vite build",
|
||||
"build:pre": "vue-tsc --noEmit && vite build --mode prebuild",
|
||||
"build:file": "vue-tsc --noEmit && vite build --mode file && node HandleHTML.js",
|
||||
"build:file": "vue-tsc --noEmit && vite build --mode file",
|
||||
"test": "vitest",
|
||||
"test:ui": "vitest --ui",
|
||||
"preview": "vite preview",
|
||||
|
||||
Reference in New Issue
Block a user