Content Fragments(CF), an implementation for re-using content across multiple locations/channels, a means for headless-CMS.
jcr:primaryType | Content Fragments(CF) is of asset type - dam:Asset to hold mixed-media content - Text and Assets. |
Types |
Note: Per 6.5 Adobe docs, it is recommended to create CF using CFM. |
Simple Template | Defines a single "Multiline text" element. |
Content Fragment Model(CFM) | Offers different data types to define the type of content. (Single line, Multiline text, Date field, Numberfield, dropdown, and so on OOB and an option to render each of this in the multifield format as well. ) |
Elements | Each of these data types that we define as part of CFM is referred to as Elements in CF |
Multiline Text element |
Note: Assets cannot be included in Plain text mode. Markdown can have reference to Assets per its syntax. |
Variations | We can create as many Variations out of Master which in turn has options to "Rename, Delete, Sync with Master". Note: Sync with Master is enabled only for Multiline Text element/data type. |
Associated Content | An option in CF lets us add related Collections to the fragment which will help list related assets when including CF in site pages. Note: We can add CF itself to be part of the same collection for easy tracking. |
Inclusion in site pages | Created CF can then be added to pages via Content Fragment and Content Fragment List component from General group or creating proxy out of core components. |
In-between content | When included on the page, we will have the means to add "in-between" content which can be
Note: These are part of the page content and not the fragment content. (as it is authored at page level after locating content fragment) |
API/Access programmatically | Below mentioned interfaces are available for accessing content fragments/templates/elements/variations and its related from com.adobe.cq.dam.cfm.* |
Pre-requisites(before creating CFM/CF) | CFM is part of the configuration and hence the same needs to be enabled in /conf via Configuration Browser. (General -> Configuration Browser)
As CF is an asset and is to be created using CFM (which acts as a template for creating CF), the same needs to be allowed at the desired DAM folder level.
|
Use cases:
- Content related to events, news articles, press releases, product details can be part of CF where we can define structured content via CFM.
- Single multiline content scenarios like privacy, terms, and conditions can be part of CF, defined at the project level can be used across locales. (by leveraging translation)
Related screenshots for reference:
No comments:
Post a Comment
If you have any doubts or questions, please let us know.