动态引入图片路径写法
<el-image
style="width: 16px; height: 16px"
:src="getAssetsImg(item.unitGrade)"
class="mr5"
/>
const getAssetsImg = (type?: string) => {
return new URL(`/src/assets/image/fx_${type}.png`, import.meta.url).href
}

浙公网安备 33010602011771号