adobe / adobe/aem-project-archetype

[MSM] Simplify content structure when singleCountry is enabled

Open
#518 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
JavaScript
Stars
596
Forks
431
Avg merge
10d 6h
Merged PRs (30d)
1

Description

When creating a site with the option `singleCountry=y` it is expected that the `country` option is ignored and that the content structure doesn't contain the country level.

* `/content/__appId__/us/en` should be moved to `/content/__appId__/en`
* `/content/experience-fragments/__appId__/us/en` should be moved to `/content/experience-fragments/__appId__/en`

There might also be a number of references that contain `us/en` that probably need to be adjusted accordingly:
* https://github.com/adobe/aem-project-archetype/blob/b5d852c68376ee38340b0d097182c3c5cbfec849/src/main/archetype/ui.frontend.general/src/main/webpack/static/index.html#L22
* https://github.com/adobe/aem-project-archetype/blob/b5d852c68376ee38340b0d097182c3c5cbfec849/src/main/archetype/ui.frontend.general/src/main/webpack/static/index.html#L34
* https://github.com/adobe/aem-project-archetype/blob/70fafeb086996913d8bff7da3bf7fba8e94cdabd/src/main/archetype/ui.tests/test-module/specs/aem/sites.js#L21-L22
* https://github.com/adobe/aem-project-archetype/blob/02f4078bdb9803a88c26a68b792bb823aa2df202/src/main/resources/META-INF/archetype-post-generate.groovy#L166
* https://github.com/adobe/aem-project-archetype/blob/02f4078bdb9803a88c26a68b792bb823aa2df202/src/main/resources/META-INF/archetype-post-generate.groovy#L219

Contributor guide

Open the contributing guide

Research direction

Start with src/main/resources/META-INF/archetype-post-generate.groovy and the referenced ui.frontend.general/static/index.html and ui.tests/specs/aem/sites.js files. Generate a site with singleCountry=y, inspect the resulting content paths and references, and verify that the country level and stale us/en references are removed or adjusted consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
groovy, java, javascript
Domain
build-system, content, web-dev
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.