let importFn = (icon)=>{
import icon from "@/assets/monitor-data/" + icon + ".png";这行还报错了
}
import icon1 from "@/assets/monitor-data/icon1.png";
import icon2 from "@/assets/monitor-data/icon2.png";
import icon3 from "@/assets/monitor-data/icon3.png";
import icon4 from "@/assets/monitor-data/icon4.png";
vue项目,本来打算写一个函数,结果import那一行还报错了,不知道为什么,大家都是怎么解决这种重复引入的呢### 问题描述
// 请把代码文本粘贴到下方(请勿用图片代替代码)
白衣染霜花
相关分类