- 发布:2025-10-29 15:00
- 更新:2025-10-29 16:42
- 阅读:24
产品分类: uniapp/App
PC开发环境操作系统: Windows
PC开发环境操作系统版本号: 22631.4890
HBuilderX类型: 正式
HBuilderX版本号: 4.45
手机系统: 全部
手机厂商: 华为
页面类型: vue
vue版本: vue3
打包方式: 云端
项目创建方式: HBuilderX
测试过的手机:
操作步骤:
热更新
热更新
预期结果:
正常显示图片
正常显示图片
实际结果:
显示空白
显示空白
bug描述:
不是绝对 偶现 只是最近概率比较大
通绝对路径直接使用
<image src="/static/image/xxxx.png">
通过组件使用 <Icon imgName="xxx">
props imgName
const imgPath = computed(()=> /static/image/${imgName}.png)
<image :src="imgPath">
通过 wgt 热更新后 这些本地图片全部不显示了 空白
2 个回复
l***@163.com (作者)
uniapp 中使用图片用哪种方式好呢 uniapp+vue3+ts
方式一:import testPath from '@/static/image/idcard-front.png'
<image :src="testPath">
方式二: <image src="/static/image/idcard-front.png">
l***@163.com (作者)
app 打包wgt 这个wgt 包含的内容是啥 static 文件夹中的内容每次打wgt热更新都会全部包含?