using next-i18next with Next.js 13 #1993
Replies: 20 comments 39 replies
-
... is there an issue with that? |
Beta Was this translation helpful? Give feedback.
-
the example is using pages directory. we can not use getServerSideProps inside app directory. so what will be the alternative? |
Beta Was this translation helpful? Give feedback.
-
WIth the new There are quite a few changes in there. While next-i18next works great with the More info: https://beta.nextjs.org/docs/upgrade-guide# |
Beta Was this translation helpful? Give feedback.
-
https://beta.nextjs.org/docs/upgrade-guide#migrating-from-pages-to-app Feel free to start a PR addressing this. |
Beta Was this translation helpful? Give feedback.
-
Also with the new app directory approach |
Beta Was this translation helpful? Give feedback.
-
Like said, feel free to start a pull request and contribute to this open source project... |
Beta Was this translation helpful? Give feedback.
-
I get the why of your comments, "just make a PR" (I do it too!) - but in this case, it's a fundamental change in how this library works with the future Next.js, and I think it would be more appropriate if it were led by a maintainer. Please don't take this as "please work for free for me"; it's the beginning of a discussion for making this library work with what Next.js will become, not a command to work on it. |
Beta Was this translation helpful? Give feedback.
-
That's why I said "...feel free to start a pull request..." ;-) |
Beta Was this translation helpful? Give feedback.
-
Before I start a PR, should this be moved to a discussion, maybe? Since the API will have significant changes, and maintainers should lead the design of those? |
Beta Was this translation helpful? Give feedback.
-
https://beta.nextjs.org/docs/app-directory-roadmap
|
Beta Was this translation helpful? Give feedback.
-
You can use native
|
Beta Was this translation helpful? Give feedback.
-
What is the current consensus on roadmap for addressing this issue? |
Beta Was this translation helpful? Give feedback.
This comment has been minimized.
This comment has been minimized.
-
fyi: https://beta.nextjs.org/docs/app-directory-roadmap#not-planned-features |
Beta Was this translation helpful? Give feedback.
This comment has been hidden.
This comment has been hidden.
-
The example here: https://github.com/i18next/next-13-app-dir-i18next-example is showing how i18next could be used on server side and client side... and also a middleware with language detection and cookie persistence... |
Beta Was this translation helpful? Give feedback.
-
Do you have an example of how to use dynamic routes? I had an error when I created the dynamic page folder 'Server Error This error happened while generating the page. Any console logs will be displayed in the terminal window.' thanks |
Beta Was this translation helpful? Give feedback.
-
Does this mean that this library is useless since Next.js 13 and we should instead use
|
Beta Was this translation helpful? Give feedback.
-
Elint complaint this when I'm building: Error: React Hook "useTranslation" cannot be called in an async function. react-hooks/rules-of-hooks |
Beta Was this translation helpful? Give feedback.
-
Hi. This because all my pages have got these 2 pages fortunatly ara pegas without any component (only a canvas). But now when I need to create a new page I would create in the app router. But this is impossible since a normal page in my case has both How can I start a migration? I dupicate |
Beta Was this translation helpful? Give feedback.
-
How we are going to use this package with Nextjs version 13 and how it will work with server components? Because I want my hole page use translation in server and get translated page from server.
previously, we were using this package like this.
export const getServerSideProps: GetServerSideProps = async ({ locale }) => {
return {
props: {
...(await serverSideTranslations(locale as string, ["common", "login", "form"])),
},
};
};
Beta Was this translation helpful? Give feedback.
All reactions