Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

Experience Fragment | localizedFragmentVariationPath | for non-standard region/language sites

Avatar

Level 3

Hello team,

We have site structure in AEM like "/content/project-site/eu/en" where as EU is europe region and EN -english site. Similarly corresponding XF structure -  Experience Fragment structure "/content/experience-fragments/project-site/eu/en/site"

 

and for German site "/content/project-site/eu/de" and XF - "/content/experience-fragments/project-site/eu/de/site".

We are using AEM SPA with reactJs to render the pages. 

 

Issue is model.json always have XF localizedFragmentVariants - "/content/experience-fragments/project-site/eu/en/site" for EU/DE site.

 

Expected localized fragment variants path for site "/content/project-site/eu/de" must be "/content/experience-fragments/project-site/eu/de/site".

 

Please let me know how we can achieve this retrieving language specific XF for EU/DE site.

We have achieved this for multipage sites but not finding way to customize for SPA pages where data exported via model.json.

 

Quick responses much appreciated. thanks

1 Accepted Solution

Avatar

Correct answer by
Level 3

Hello, resolved the issue by extending the abstract class "AbstractComponentImpl" and implementing "ExperienceFragment" interface.

 

and we need to override the methods "getLocalizedFragmentVariationPath()" and getChildren() methods.

View solution in original post

1 Reply

Avatar

Correct answer by
Level 3

Hello, resolved the issue by extending the abstract class "AbstractComponentImpl" and implementing "ExperienceFragment" interface.

 

and we need to override the methods "getLocalizedFragmentVariationPath()" and getChildren() methods.