3

In AEM, I see that its good to make the header as an experience fragment that making it as a component. Any reasoning for that?

2 Answers2

1

Both are valid. But the reason the Experience Fragment method is better comes down to a few things:

  1. Fewer components, reuse of existing components.
  2. Changes to the header and footer may be accomplished without the need for development
  3. The header and footer are self contained and could be queried for use outside of AEM if necessary.
  4. Experience Fragment variations allow you to create different header/footer options for various scenarios, but keep them in one place that is easy for authors to understand.
Jeff Foxx
  • 36
  • 2
0

According to AEM documentation, a page template can contain essential components like below to make up a complete page with header, body and footer

  • Navigation Component

  • Container Component

  • Experience Fragment

Reference documentation : https://experienceleague.adobe.com/docs/experience-manager-core-components/using/get-started/localization.html?lang=en

Sarang Kakkoth
  • 381
  • 3
  • 9