metal.js
metal.js copied to clipboard
Some use cases do not work well when HTML2IncDom is called
Disclaimer
When we have an application in soy that the value of our STATE is set to isHTML
for true
:
MyComponent.STATE = {
text: {
isHTML: true,
value: '<p><strong><em><u><a href="http://t4gdgreg" target="">rtetettrttrrtert</a></u></em></strong></p>'
}
}
It calls the function HTML2IncDom.buildFn(...)
to do the parser, but we have some use cases like the one above that it returns the wrong parser, this is reflected in the DOM, it seems to be some problem with the tag a
inside the parser, but not sure about that.
This is quite common to happen in editors like AlloyEditor, to stylize the text.
Current behavior

Expected behavior

/cc @alinedoleron