Hi,
criteria: provide navigation data as json to other front end applications.
Here is sample navigation I am looking to generate
I have below structure to generate navigation menu up to 3 levels.
Navigations structure:
sub menu can have other nested sub menus.
How can I achieve this using content fragments ? It seems "fragment reference" only outputs the cf path rather than data of fragment referred. I do not see any "nested multifield" support for content fragments.
Thanks,
Sri
해결되었습니다! 솔루션으로 이동.
토픽은 커뮤니티 콘텐츠를 분류하여 관련성 있는 콘텐츠를 찾는 데 도움이 됩니다.
조회 수
답글
좋아요 수
You can utilize GraphQL to read Content Fragment data, including the ability to retrieve referenced data.
query {
articleList { // Article Content Fragment
items {
title
author { // Author Content Fragment
_path
name
}
}
}
}
You could create a custom endpoint at server-side to read the reference fragments data and add it in JSON response.
You can utilize GraphQL to read Content Fragment data, including the ability to retrieve referenced data.
query {
articleList { // Article Content Fragment
items {
title
author { // Author Content Fragment
_path
name
}
}
}
}
Hi @sreenu539
Did you find the suggestions from users helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community.
This would need customization. Just like Navigation Sling Model derives information from pages, we would need to derive information from CF hierarchy.
Other choice is to use GraphQL (preferred option), since an external application needs this data. Please review queries on: https://experienceleague.adobe.com/en/docs/experience-manager-learn/getting-started-with-aem-headles...
@sreenu539 Did you find the suggestions from users helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community.
조회 수
답글
좋아요 수