What's the best way to expose and consume a content fragment

Avatar

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile
pavanr6387218
Level 2

14-12-2018

Hi Team,

    

     The scenario is that the content authors are going to create several content-fragments. These content-fragments will have to be then consumed by AEM and Mobile App, to apply appropriate styling to be published to the end customer.

     I have gone through several documents where a content-fragment is associated with a page and then exposed as a JSON. Are there any better ways in which we can expose the content-fragment?

What's the best way to expose and consume content fragments within AEM and for an App?

Replies

Avatar

Avatar
Validate 1
Level 10
edubey
Level 10

Likes

277 likes

Total Posts

1,502 posts

Correct reply

392 solutions
Top badges earned
Validate 1
Give Back 50
Give Back 5
Give Back 3
Give Back 25
View profile

Avatar
Validate 1
Level 10
edubey
Level 10

Likes

277 likes

Total Posts

1,502 posts

Correct reply

392 solutions
Top badges earned
Validate 1
Give Back 50
Give Back 5
Give Back 3
Give Back 25
View profile
edubey
Level 10

14-12-2018

You can use content services from aem to get the CF

here is a demo with react app

https://helpx.adobe.com/experience-manager/kt/sites/using/content-services-tutorial-use/part7.html

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

14-12-2018

Of course - the basic use of them is to display within an AEM page - as discussed here -- Adobe Experience Manager Help | Working with Adobe Experience Manager 6.4 Content Fragments

Avatar

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile
pavanr6387218
Level 2

14-12-2018

Hi Sam,

     We have multiple channels where the content has to be shared. The content which is created via the content-fragments has to be consumed by the particular channel to apply the style(CSS) to achieve the look and feel.

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

14-12-2018

Praveen answer is correct - you would use Content Services in that case.

Avatar

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile
pavanr6387218
Level 2

14-12-2018

Hi Edubey,

          Thank you for the article reference. It is helpful but they are using multiple content-fragments onto a page which is then exposed. Are there any alternative ways in which we can expose this content-fragment data?

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

14-12-2018

While waiting to Praveen to reply - i recommend that you watch this Ask the AEM COMMUNITY Experts on Content Services - AEM Content Services: What, Why, and How?

Avatar

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile

Avatar
Give Back 5
Level 2
pavanr6387218
Level 2

Like

1 like

Total Posts

11 posts

Correct reply

0 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 3
Ignite 1
View profile
pavanr6387218
Level 2

17-01-2019

I ended up creating an API which exposes the content fragment based on Content Fragment name