Closed aysiscore closed 1 year ago
Once you add it to allowedAttributes, you'll need to look at allowedClasses.
Even with allowedClasses: [*]
or allowedClasses: ['infosnippet']
it strips the class attribute out of the tag.
Please reopen as its not solved
Did you add class
to allowedAttributes
? If you did then please provide a failing unit test showing the problem.
I have configured sanitize-html like this:
When I send the following content to the server before sanitize-html is called it is like this:
Once I run sanitize-html on the above content the
class
attribute on the<aside>
tag is being stripped, so I end up with this:Looking at the docs I believe I have configured it properly to allow
class
attributes on theaside
tag and in fact ALL tags using the wildcard.Is this a configuration issue or a bug?