具体报错如下:
解决办法:
修改package.json的打包命令
"build": "vite build && node --max_old_space_size=40960",
"build:docker": "vite build --outDir ./docker/dist/",
改为
"build": "node --max_old_space_size=4096 ./node_modules/vite/bin/vite.js build",
"build:docker": "node --max_old_space_size=4096 ./node_modules/vite/bin/vite.js build --outDir ./docker/dist/",