vue设置背景图片
现在data里面定义:
note: { backgroundImage: "url(" + require("../../assets/home/bigdatabak.png") + ")", backgroundRepeat: "no-repeat", backgroundPosition: "center", }
<div style="height: 100%; width: 100%;" class="note" :style ="note">
</div>
现在data里面定义:
note: { backgroundImage: "url(" + require("../../assets/home/bigdatabak.png") + ")", backgroundRepeat: "no-repeat", backgroundPosition: "center", }
<div style="height: 100%; width: 100%;" class="note" :style ="note">
</div>