Hi Bruce
As part of component (say mycomponent), I have angular.json.jsp with some json content (In actual functionality this would be constructed through dialog properties)
{
items:
[
{
'content': 'contentValue',
'another': 'anotherValue'
}
]
}
In controller.js.jsp there is a javascript promise from page component (similar to implementation in /libs/mobileapps/components/angular)
data.then(function(response) {
$scope.<c:out value="${componentDataPath}"/> = response.data["<c:out value='${componentPath}'/>"].items;
});
Now this component (this has frameworkType=angular property) is dragged in angular based template. There JSON from angular.json.jsp is set to $scope. This works fine in normal page.
Now say if I have 3 pages (Page1, Page2, Page3).In page 1 I have mycomponent dragged. In Page2, Page3, I drag reference component (/libs/foundation/components/reference). In both pages I refer to mycomponent authored in Page1. But here the call is not made to controller.js.jsp (Prob because reference node is not having frameworkType=angular). I was trying to have json in one page and refer in other 2 pages.
{ items: [ { 'content': '<%= xssAPI.encodeForJSString(properties.get("text", "")) %>', 'textIsRich': '<%= xssAPI.encodeForJSString(properties.get("textIsRich", "false")) %>' } ]}