Ask questions如何通过v-bind:style动态生成背景图?

在通过v-for出来子集之后,要生成当前节点的背景图,通过v-bind:style="{background:url(list.Cover)}" 无法正确便利出结果. [Vue warn]: Error when evaluating expression "{background:url(list.Cover)}". Turn on debug mode to see stack trace. 请尤大大解答下,谢谢


Answer questions vidis01

What it is?

2019-10-30, tr, 14:16 JustDoIt521 rašė:

:style="{backgroundImage:url(${gift.reward_pic}), color: 'red'}" 如果多个属性的话 这样写

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe .


Related questions

force re-computation of a computed property hot 3
Error thrown when using transition-group with conditionally rendered children hot 3
Vuejs type inference does not work with TS 3.4.x hot 3
Property 'X' does not exist on type CombinedVueInstance using TypeScript Prop Validator hot 2
[Vue warn]: Error in nextTick: "RangeError: Maximum call stack size exceeded" while navigating to another route hot 1
关于keep-alive缓存页面问题请教 hot 1
Can not clear slot content with vue@2.5.3 hot 1
TypeError: Cannot read property 'toLowerCase' of undefined at emptyNodeAt hot 1
VNode.componentInstance is undefined when rendered by a functional component hot 1
Korean input trigger keydown event twice hot 1
Proposal: Template inheritance using the slots mechanism hot 1
Memory leak when using "transition" and "keep-alive" hot 1
Error in v-on handler: "RangeError: Maximum call stack size exceeded" hot 1
Different functional componens has the same key hot 1
IE11, console print: [Vue warn]: Error in nextTick: "Error: Invalid argument." But work well with chrome hot 1
Github User Rank List