Create Experience fragment in aem

Experience fragment are a new feature introduced in aem 6.3. If different pages are using the same content / component then author can put those component / content in single experience fragment and can use this XF in all the required pages.

In this post we will see how to create Experience fragment using existing/out of box template

Step 1: Go to AEM start console for me (http://localhost:4502/aem/start.html) .


Click on Experience Fragment.

Once You Click on Experience Fragment it will open the XF console where you can create Folder and Experience Fragment.

We create folders as per project requirement Like we are working on XYZ project which is having sites in EN,US,AU, UK so we will create folder as per project structure.




Step 2: Once you are done with required Folders creations. Start creating XF. To create XF from create icon drop down select Experience Fragment.


Enter the Experience Fragment details Like (Title, Name, Description & tags).


Click Next.

Step 3: Choose Experience Fragment template. You can create your own Experience fragment template or can you existing template (I am using existing template).


Click Create.

Click save or Open in next pop up.

Step 4:  This time is to edit the XF created. To Edit the XF Go to XF console select the XF fragment you created (Sample Experience Fragment).

Click Edit.


Step 5: Once experience fragment is open here drag and drop the required component and content which you want to re-use in pages.


Step 6: Experience Fragment is ready to use. To use XF on page add Experience fragment component inside parsys.

Step 7: Configure Experience fragment. Add the XF fragment path while configuring XF.

Note: While configuring XF don't add .html extension in path 



/content/experience-fragments/en/LearnAEM/SampleExperienceFragment/sample-experiencefragment

Save it.

Page will look like below once you added & configured XF



KEEP EDUCATING YOURSELF!!!!


Comments

Popular posts from this blog

AEM in docker

Sling API vs JCR API

Creating or finding .M2 folder