Tech Insights

AEM Experience Fragments: An Introduction

What are Experience Fragments in AEM?

It’s the experience fragment (XF) feature in Adobe Experience Manager unveiled in version 6.3. AEM experience fragments make up a group of one or more components containing both content and how to display the content. The grouping forms an experience that should make sense on its own independently of where it’s used. A very simple example would be a single product title, product description, and product image.

In this post we’ll sketch out a brief overview of Experience Fragments in AEM. In a later post, we’ll go into much more detail about AEM experience Fragments.

As with most things in AEM, the central idea is content reuse. Author it in one place and use it in several different places or with several different variations of it. Here’s a quick run-down of what makes an XF and XF:

  • Based on a template for structure
  • Consists of one or more components with a defined appearance
  • Intended to be reused, reordered, or resized
  • Can be modified into multiple variations

Without the XF feature, if an author wants to reuse parts of a page as an “experience”, they would need to copy and paste that experience repeatedly. Manually, creating and maintaining these fragments on pages is time-consuming and prone to error. The XF feature eliminates the need for this kind of copy/paste.

When Should You Use Experience Fragments in AEM?

For reuse

  • Experiences that will be reused with the same or similar content

To deliver content as a platform for outside services

  • Any service that wants to use AEM as a content delivery platform
  • Embedding content in 3rd party touchpoints

To easily make different variations

  • Channel or content-specific variation
  • Experiences that make sense to a group (e.g., a campaign with different experiences across channels)

For omnichannel commerce

  • Sharing commerce-related content on social media channels at scale
  • Making touchpoints transactional

Are you in IT? Join our team!

The AEM Experience Fragments Architecture

  • Editable Templates, which in turn are defined by Editable Template Types and an AEM Page component implementation, define the allowed AEM Components that can be used to compose an Experience Fragment.
  • AEM Experience Fragments are instances of Editable Templates that represent logical experiences.
  • Experience Fragment variations adhere to the Editable Template, but have variations in the represented experience (content and design).
  • Experience Fragments in AEM can be exposed/consumed by:
    • Using Experience Fragments in AEM Sites (or AEM Screens) via the AEM Experience Fragment component.
    • Exposing an Experience Fragment variations content as JSON (with embedded HTML) via AEM Content Services and API Pages.
    • Directly exposing an Experience Fragment variation as “Plain HTML”.
    • Exporting Experience Fragments to Adobe Target as either HTML or JSON offers.
      • AEM Sites natively supports HTML offers, however, JSON offers require custom development

Did you get all that? Here’s a graphic to illustrate some of this:

Stay tuned for our next post on Experience Fragments in AEM where we dive into more detail.

Author: Iryna Ason