Showing posts with label ContextHub. Show all posts
Showing posts with label ContextHub. Show all posts

Sunday, 13 January 2019

Targeting content in AEM

AEM enables to target content for different audience.

This post will explain how to target title component to display content based on user's location and do A/B testing.

Create a web page called Target under we-retail website.


Click here to check how to enable ContextHub.
Navigate to AEM instance and create Brand and activities. 


Saturday, 12 January 2019

Cannot read property 'extend' of undefined': ContextHub

While adding ContextHub to AEM site could see below errors

Change ContextHub entry in head section from 
<sly data-sly-resource="${'contexthub' @ resourceType='granite/contexthub/components/contexthub'}"/>

to 

!--/* Include Context Hub */-->
<sly data-sly-call="${clientlib.js @ categories='granite.utils'}"/>
<sly data-sly-resource="${'contexthub' @ resourceType='granite/contexthub/components/contexthub'}"/>


Click here to check how to setup ContextHub in AEM.

Using script reference in AEM ContextHub

While creating audience in AEM contextHub, we see a component called Script Reference. When we drag-n-drop the component, we don't see any scripts by default in the drop down.