un-pany / v3-admin-vite

☀️ A vue3 admin template | vue3 admin/element plus admin/vite admin/vue3 template/vue3 后台/vue3 模板/vue3 后台管理系统
https://un-pany.github.io/v3-admin-vite
MIT License
5.27k stars 893 forks source link

Static resources mapping issue in packaging process #103

Closed DDDPG closed 1 year ago

DDDPG commented 1 year ago

When packaging, in vite.config.ts, import the env VITE_PUBLIC_PATH as public basic dir, but the static resource in dist folder did not changed correspondingly, because assetsDir was “static”, which is static, I think it is supposed to be VITE_PUBLIC_PATH.slice(1, -1) then the path mapping is right. From my point of view this is more convinent than memorizing the static mapping rules in DockerFIle or other files.

Apology for the interruption few days ago of merging request issue.🏳️

pany-ang commented 1 year ago

"assetsDir" doesn't seem to need to be synchronized with "VITE_PUBLIC_PATH". I don't particularly understand the scenario you mentioned