lundi 9 avril 2018

Ember: correct way to render background image in an element

This is the html:

<div style="background-image: url();"></div>

This renders all good, but keep receiving this warning:

warn.js:48 WARNING: Binding style attributes may introduce cross-site scripting vulnerabilities; please ensure that values being bound are properly escaped. For more information, including how to disable this warning, see https://emberjs.com/deprecations/v1.x/#toc_binding-style-attributes. Style affected: "background-image: url(https://www.userImage.com/cuautemok.png);"

Tried:

<div style=background-image: url();></div>

<div style="background-image: url('');"></div>

<div style="background-image: url("");"></div>

and many more... No luck yet.




Aucun commentaire:

Enregistrer un commentaire