Reputation: 3995
I have this code:
show.jade:
foreach promo in promotions
include _promotion
_promotion.jade:
img.thumb(src="#")
I'm trying to set the src of the img tag dynamically with promo.image_url
, and I can't seem to figure out the syntax. I've tried every combination I can think of, with no luck. This, specifically, does not work:
img.thumb(src=promo.image_url)
I know that this works for simple tags:
p= promo.image_url
But I can't figure out how to get the = sign into the img src correctly.
Upvotes: 1
Views: 278
Reputation: 26
img.thumb(src="#{promo.image_url}")
though I hope you haven't had to wait this long!
Upvotes: 1