aem - currentStyle.<propertyName> is returning null in cq5 publisher, which is working perfectly fine in author -
i using sightly access design dialog properties component.
<span data-sly-test="${currentstyle.delimiter}">${currentstyle.delimiter}</span>   but getting empty string.
i tried resolve issue trying out following.
- activating design node
 - deleting page , creating new page.
 - deleting components , dragging , dropping component again on page.
 - i checked json output of currentdesign , values trying access available there.
 
you have 2 options
- in preview/ publish mode fetch design values via currentdesign.getjson(), parse value returned , key values want json object.
 - you may solve removing 1 line of code template head.js. if inheriting template 1 of "/libs" ( sightly) page , there head.js having below line of code can overlay head.js in template , commented out below line of code.
 
if (wcmmode.disabled) {     request.setattribute(packages.com.day.cq.wcm.api.components.componentcontext.                   bypass_component_handling_on_include_attribute, true); }
comment out , normal.
Comments
Post a Comment