How to create json ui labels that can be authored and exported to Angular in SPA AEM 6.5 | Community
Skip to main content
September 25, 2023
Solved

How to create json ui labels that can be authored and exported to Angular in SPA AEM 6.5

  • September 25, 2023
  • 2 replies
  • 782 views

Hi,

I am currently using I18n feature to store the json under /apps and served the file using /libs/cq/i18n/dict.en.json

The json contains key values of error messages required in the field validations and api validation messages in the form.

Issues found in my I18n approach:

  • Since the messages are controlled by the developers we need deployment for every change in the json. Can we make it author friendly so that deployments can be avoided.
  • When we have two projects containing dict.en.json under its respective /apps folder the url /libs/cq/i18n/dict.en.json contains one of the projects values when accessed until we delete one of the file the other file is not used.

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Jagadeesh_Prakash

@saddrab8102822  

 

To the first point in the issue, below are the possible options to solve it

1. Create a custom AEM page which can update the i18N node directly into the i18N location
2. Maintain the i18N as a excel sheet in DAM location and its easy for authors to update the csv or xlxs sheet and update in DAM location

For second point in the issues mentioned,
You can maintain the .en.json file and read it from a location

2 replies

Jagadeesh_Prakash
Community Advisor
Jagadeesh_PrakashCommunity AdvisorAccepted solution
Community Advisor
September 25, 2023

@saddrab8102822  

 

To the first point in the issue, below are the possible options to solve it

1. Create a custom AEM page which can update the i18N node directly into the i18N location
2. Maintain the i18N as a excel sheet in DAM location and its easy for authors to update the csv or xlxs sheet and update in DAM location

For second point in the issues mentioned,
You can maintain the .en.json file and read it from a location

kautuk_sahni
Community Manager
Community Manager
September 26, 2023

@saddrab8102822 Did you find the suggestion from @jagadeesh_prakash 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.

Kautuk Sahni