ssr-with-i18n icon indicating copy to clipboard operation
ssr-with-i18n copied to clipboard

TranslateFSLoader fails to find path to traduction file.

Open vbonne opened this issue 3 years ago • 1 comments

Hi Dimitry,

Very good your article on indepth.dev I implemented everything like you recomended but then I can see both : 1 - the script with the translations keys in the page served by the server 2 - the request for the Json is also visible in the network logs,

I figured out that when I change the language the page is not requested again to the server, so the script stays with the language loaded the first time the page was loaded, so that is why the http request is done to the server to get the new language. So where is my mistake in the implementation ? Should force a page reload when switching language ( but I doubt the language would change on the server side when making the change on the browser) or should i include the language in the url ?

Many thanks for your post and your github project, this is the only compehensive and functional tutorial I found after 3 days strugguling with ngx-translate and ssr. Hope to hear from you soon.

EDIT : I initially reported an SSR error but that was my mistake, your github exemples are fine I just got mixed up between the steps

vbonne avatar Oct 20 '20 18:10 vbonne