Reputation: 1679
I have been trying to implement ngx translation in the nested lazyloaded module, but have not been able to do so. The only issue I'm facing is that the language doesn't change in the nested lazyloaded module whenever I change it through the selector. HttpLoader is working fine, everything else is working fine. The code is an entire project. I wish I could post the code as well. Can someone refer me to helpful material about implementing ngx translation in a nested lazyloaded module
Upvotes: 4
Views: 2240
Reputation: 6706
In your nested lazy-loaded module, import the TranslateModule
with the extend
option, to allow the module to get the translation from the first lazy-loaded module.
You can do that like the following:
imports: [TranslateModule.forChild({ extend: true })]
Upvotes: 1