gilsdav / ngx-translate-router

Translate routes using ngx-translate
131 stars 43 forks source link

HttpLoaderFactory Function run advance APP_INITIALIZE #144

Open tranthien87 opened 1 year ago

tranthien87 commented 1 year ago

Hi everyone! I have 2 issues when integrating ngx-translate-router in my Angular App.

The first issue when running HttpLoaderFactory is to get a list of languages to replace the locales.json file. The HttpLoaderFactory function always runs in advance APP_INITIALIZE - get the config file, how to run order follow?

The second one: how to use router link replace to /<a href="#id>

Thank you for helping in advance!

giacomo commented 1 year ago

For localized urls you should use <a [routerLink]="['/some', 'path'] | localize">Test</a>