@jelhan wrote:
I'm wondering if there is any recommendation how to bind a style attributes?
attributeBindings: ['style']
and<span style={{style}}>
both require CSP policystile-src: 'unsafe-inline'
. On the other hand using jQuery.css()
or manipulating CSS Object Model (CSSOM) directly doesn't feel like "the ember way" and will not work with fastboot.There is an addon called ember-cli-csp-style which tries to help with a
styleBindings
property. It manipulates CSSOM directly in latest release. Current master seems to be broken and violations CSP.I found nearly nothing about this topic even so dozens of ember-addons require
stile-src: 'unsafe-inline'
...
Posts: 1
Participants: 1