Best practice with content management #613
-
Hi, I am just starting to use this framework and so far I'm really enjoying it. Now I have a basic understanding of how it works I was wondering how you would organize the code structure for a whole website that would have several pages with dozens of translation items. I guess I would make separate translation files (one for each page ? I'm a beginner I am not sure how to do it...) ? Is it ok to sync load all the translations at start ? I code my website with sveltekit and do not update so often so I'm expecting to hard code everything... Thanks for your help ! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I'm happy to see you like it :) You could load your translations depending on the route using the I would not recommend loading the translations in a synchronous way, because you would load all locales at once. By loading them async, only a single locale needs to be loaded. |
Beta Was this translation helpful? Give feedback.
I'm happy to see you like it :)
You could load your translations depending on the route using the
namesapace
functionality. If it is just a small website with a few translations, you don't really need to do that.I would not recommend loading the translations in a synchronous way, because you would load all locales at once. By loading them async, only a single locale needs to be loaded.