-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Hi,
when piping a gson JsonObject straight into a script tag js expression, it should not throw an expression expected error:
The above code produces valid javascript / markup and works fine.
public JsonObject getPageObject() {
// [...]
}<sly data-sly-use.model="core.models.DatalayerModel"
data-sly-use.pageInfo="core.models.PageInfo">
<!--/* async include websdk library */-->
<script src="${model.webSDK @ context='uri'}" async></script>
<!--/* initialize client datalayer */-->
<script>
window.datalayer = window.datalayer || [];
datalayer.push({
"event": "pageView",
<!--/* false positive, pageObject is a gson JsonObject. This works. */-->
"page": ${model.pageObject @ context='unsafe'},
});
</script>
</sly>Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels