Skip to content

Conversation

@sergiojoker11
Copy link

Extract an abstract class with common functionality.
Create a loader that loads from n-translation files and merge the translations.
In case of key collision, the last resource passed in (its translations) has more priority. Thus, the developer still has the control on priorities.
The existing TranslatePoHttpLoader functionality is untouched.

This allows to keep your translations organised (per module/library in subfolders) within the main application. (Some organization might want to keep the translations centralised).

Potential/desired improvement
Merge strategies.

…that loads translation files from paths and merge them
@sergiojoker11
Copy link
Author

Please, my organization is holding on this. Could anyone have a quick look?

@RignonNoel
Copy link

I love this one! Hope it will be merged!

@sergiojoker11
Copy link
Author

@RignonNoel in the meantime, I had to publish the package in order to unblock my team. Feel free to use it, it is public.
https://www.npmjs.com/package/@flexys/ngx-translate-po-http-loader

@RignonNoel
Copy link

@sergiojoker11 Thanks! I will wait a little bit since this feature is not an urgency for me but i will definitively use it in the future. It's really more easy to understand for translators if files are splitted!

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

Successfully merging this pull request may close these issues.

2 participants