-
I'm currently working on a multilingual ecommerce with nextjs. I'm currently using getServerSideProps instead of getStaticProps but I'm looking to fully migrate to static rendering wherever I can. The issue I currently have is that some multilingual data I have to fetch is in the database. I store the current language with a cookie. The problem with this approach is that I can't fetch the data in the current language inside getStaticProps because I can't access cookies inside getStaticProps. What is the best way to access database stored multilingual data in static generated sites? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
We currently have an open RFC for i18n routing: #17078. It aims to cover cases like yours because currently doing i18n with Next.js can be hard and tedious. Follow that RFC if you want to know more about our progress there! |
Beta Was this translation helpful? Give feedback.
We currently have an open RFC for i18n routing: #17078. It aims to cover cases like yours because currently doing i18n with Next.js can be hard and tedious. Follow that RFC if you want to know more about our progress there!