Expand my Community achievements bar.

Nomination window for the Adobe Community Advisor Program, Class of 2025, is now open!
SOLVED

Use SPA editor for Experience fragments for remote SPA(Next js or React) Application

Avatar

Level 2

Hi, we want to implement header and footer for AEM Headless with remote SPA(Next Js). Will that be possible by using experience fragments? Will I get SPA editor for editing the experience fragments components? Please suggest some pointers? Thanks in Advance.

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Level 3

Experience fragment should be created as is only , but make sure remote SPA editor should be configurated with AEM instance appropiately.

Reference : https://experienceleague.adobe.com/en/docs/experience-manager-learn/getting-started-with-aem-headles...

 

View solution in original post

3 Replies

Avatar

Community Advisor

Hi, 

Yes, you can edit XF via SPA editor; you just need to follow the same principles to make any component editable in the SPA editor. Map the component, use a sling model, and register it in the SPA code. Keep in mind that for the header and footer, you should have two components mapped into the SPA: the XF and also the header/footer.

You can check this example of how components are mapped in NextJS:

https://github.com/adobe/aem-headless-app-templates/blob/main/nextjs-remotespa/components/import-com...

 

 

Hope this helps.



Esteban Bustamante

Is there any reference on how to create experience fragment template that supports remote SPA. Any pointers would be helpful.

Avatar

Correct answer by
Level 3

Experience fragment should be created as is only , but make sure remote SPA editor should be configurated with AEM instance appropiately.

Reference : https://experienceleague.adobe.com/en/docs/experience-manager-learn/getting-started-with-aem-headles...