jpkha / nextjs13-storyblok

https://nextjs13-storyblok.vercel.app
32 stars 9 forks source link

Multilanguage example needed #5

Closed cgpro closed 1 year ago

cgpro commented 1 year ago

Tried the repo and it works very well so far. If I add a translation, I get an error message.

Unhandled Runtime Error Error: Error: [object Object]

I have only one start page in my space with German and English with one content text block for testing. (Default Element: Teaser)

image

Error: image

I would be super happy to get some help.

jpkha commented 1 year ago

@cgpro Hello you can check this branch. I made a POC one with i18n which is working fine. I took from the example from Nextjs directly : https://github.com/jpkha/nextjs13-storyblok/tree/feat/sb-i18n.

One of thing I need to solve, is how to handle the root path for the default language. But you can get your inspiration already.

I will clean up a bit the next days.

Resources :

cgpro commented 1 year ago

Works like a charm! 👍 Jepp, played around for the last two days with i18next, but that was a bit too tedious for me with the many json files per content page. 😋

jpkha commented 1 year ago

Thank you for your feedback and your sponsorship 😻 .