You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the translations for each language live in one file. As the app grows this file will become really big, ugly, and hard to maintain. Look into the following options and come up with a potential solution/implementation.
Option 1. Look into setting up something where each component has an associated language file. We could use the pre-commit hook to run a script that combines all these files into one big file like we have now. There is the chance of having non-unique names so we may need to do something like add a prefix to the json object to force a unique structure... maybe use the angular component selector since those are supposed to be unique and we shouldn't have duplicates anywhere in the project. With this approach we won't have to change anything relating to how the translations are loaded.
Option 2. Another thing to look into would be on-demand loading of the json language files. Currently the translations for the entire app are immediately downloaded even though we may only need a small fraction of what's in there. It would be a lot more efficient if we could figure out how to load/cache the translations for specific components only when we need them. This is a big change to how everything is setup now so it would be a lot of work.
The text was updated successfully, but these errors were encountered:
Currently the translations for each language live in one file. As the app grows this file will become really big, ugly, and hard to maintain. Look into the following options and come up with a potential solution/implementation.
Option 1. Look into setting up something where each component has an associated language file. We could use the pre-commit hook to run a script that combines all these files into one big file like we have now. There is the chance of having non-unique names so we may need to do something like add a prefix to the json object to force a unique structure... maybe use the angular component selector since those are supposed to be unique and we shouldn't have duplicates anywhere in the project. With this approach we won't have to change anything relating to how the translations are loaded.
Option 2. Another thing to look into would be on-demand loading of the json language files. Currently the translations for the entire app are immediately downloaded even though we may only need a small fraction of what's in there. It would be a lot more efficient if we could figure out how to load/cache the translations for specific components only when we need them. This is a big change to how everything is setup now so it would be a lot of work.
The text was updated successfully, but these errors were encountered: