We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Metal treats only the first level value for html in STATE in soy, there are cases with values in the second level or more that can accept html.
html
Consider:
App.STATE = { sections: Config.arrayOf(Config.shapeOf({ htmlContent: Config.any(), })), };
Soy:
{@param sections: list<[ htmlContent: html ]>}
Validating Metal to check for an html happens in Soy.js#L137 Soy.js#L57 the way we check it requires it to be only on the first level.
App.STATE = { sections: { value: [ { htmlContent: { isHtml: true, } } ] }, };
Even if we put isHtml the validation of Metal requires that it be in the first level, see Soy.js#L129.
Maybe we have to change the way we will check this in the state, the problem can be more complicated, it has to be studied.
Second-level values or more in the Html state value must be rendered.
Metal escapes the contents of htmlContent with html and does not treat.
htmlContent
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Summary
Metal treats only the first level value for html in STATE in soy, there are cases with values in the second level or more that can accept
html
.Use case
Consider:
Soy:
Validating Metal to check for an html happens in Soy.js#L137 Soy.js#L57 the way we check it requires it to be only on the first level.
Consider:
Even if we put isHtml the validation of Metal requires that it be in the first level, see Soy.js#L129.
Maybe we have to change the way we will check this in the state, the problem can be more complicated, it has to be studied.
Expected behavior
Second-level values or more in the Html state value must be rendered.
Current behavior
Metal escapes the contents of
htmlContent
with html and does not treat.The text was updated successfully, but these errors were encountered: