Search code examples
aemsling

AEM 6: How to customize Reviews Essentials Component


I would like to customize the standard component Reviews Essentials. For this Purpose I have copied libs\social\reviews\components\hbs\reviews\review.review.hbs to apps/myProject/components/social/reviews/hbs/reviews/review.hbs in my Project. In this file I have added some <dev>test</dev> just to test, if the copied file review.hbs override the original file. I have deployed and tested but nothing changes :(. Do I have to do something else to tell the framework to use my review.hbs instead of the original?


Solution

  • Putting your changes in a directory starting with /apps/myProject/components... means that you started to create your own component identified with the sling:resourceType:

    myProject/components/social/reviews/hbs/reviews

    instead of just creating an overlay that extends or modifies the default component with the sling:resourceType social/reviews/components/hbs/reviews

    To extend the default social review component with your adaptions requires to create an overlay in /apps but without your project specific prefixes:

    /apps/social/reviews/components/hbs/reviews/reviews.hbs