Open caoyanxuan opened 3 years ago
var myxss = new xss.FilterXSS({ css: false, }); myxss(<span style=\"color:#f39c12\">123</span>) // => <span>123</span> i need style attr
me too!
By default any style attribute is removed, so you also need to allow it.
style
From the README.md
README.md
If you allow the attribute style, the value will be processed by cssfilter module.