Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmf build for help does not take culture into consideration #443

Open
iurifarenzena opened this issue Nov 12, 2024 · 0 comments
Open

cmf build for help does not take culture into consideration #443

iurifarenzena opened this issue Nov 12, 2024 · 0 comments

Comments

@iurifarenzena
Copy link

If you have a help project and want to have it written in more than one language, the files generated from templates do not take the culture into account.

For example, lets say you have a DEE described in two languages, the neutral one and Taiwanese Chinese (zh-TW).
After cmf build the cmf-custom-help.deeactions_template is going to generate a cmf-custom-help.deeactions.md file with duplicated entries.
image

The GenerateBasedOnTemplatesCommand command should be able to identify the supported cultures configured in the documentation app (config.json > general.supportedCultures) and generate separated .md from the _template for each one. It should also support having a template for each culture as well.
For example, lets consider the following config:

  "general": {
    "supportedCultures": [
      "en-US",
      "zh-TW"
    ],
    "startup": {
      "startupCulture": "en-US",
    },
  },

Then under templates we would have two template files:

  • cmf-custom-help.deeactions_template
  • cmf-custom-help.deeactions.zh-TW_template

After build it would have generated two .md files:

  • cmf-custom-help.deeactions.md: lists all .md files from the cmf-custom-help.deeactions folder that do not have a culture code in their name
  • cmf-custom-help.deeactions.zh-TW.md lists all *zh-TH.md files from the cmf-custom-help.deeactions folder
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant