Internationalization in NextJs 14 with Next-Intl | i18n

  Рет қаралды 56,332

Cand Dev

Cand Dev

Күн бұрын

In this video, we will explore the implementation of next-intl within the Next.js app router using server components. Additionally, we will demonstrate the creation of a select button in the navbar, allowing users to switch between the English and Indonesian languages.
👨‍💻Code:
[github] github.com/can...
🔗Source:
[next-intl docs] next-intl-docs...
🚀Live:
nextlingo-beta...
#programming

Пікірлер: 102
@florentgironde7279
@florentgironde7279 20 күн бұрын
you saved my life more than GPT 4o for sure ... Thanks you
@xDiagone
@xDiagone 5 ай бұрын
The best tutorial for nextjs translations. Literally the only tutorial that worked for me the first time, perfectly explained and fully functional. Thanks a lot!
@SUlutas
@SUlutas 5 ай бұрын
I was looking for a server-side internationalization package for a next.js project. And I found it! Thank you very much!!!
@IvoTsochev
@IvoTsochev 5 ай бұрын
Great video! Probably the best explanation about Internationalization in Nextjs so far
@mamlzy
@mamlzy 7 ай бұрын
bangga ada orang indo, bikin tutorial pake bahasa inggris di web dev
@CandDev
@CandDev 7 ай бұрын
Terimakasih, yuk kita belajar bareng disini 😁
@ExtraMad0
@ExtraMad0 5 ай бұрын
men this is the best explanation that I have been seen
@rayusaki88
@rayusaki88 3 ай бұрын
Thanks a lot! Straight forward tut! Learned something nice 👌🏼
@osw2050
@osw2050 3 ай бұрын
the best and only tutorial on youtube
@catweb666
@catweb666 6 ай бұрын
Thanks, I was searching for long for this kind of video
@marcoB0815
@marcoB0815 5 ай бұрын
Great video! Helped me a lot. Thanks!
@hosseinjafari2896
@hosseinjafari2896 4 ай бұрын
It was very helpful for me.thanks a lot.
@iPankBMW
@iPankBMW 6 ай бұрын
But its so slow with next-intl.... On each page request the page fetches the correct translations for like 0.2seconds... Either we block whole page render till translations are done or wrap translated parts in suspense which adds a lot of code + comlexity..
@mamzouj
@mamzouj 18 күн бұрын
thank you sharing code good work bro
@ThisIsLiving__
@ThisIsLiving__ 3 ай бұрын
saved me twice on two different projects 😃
@MinaNassef-p6r
@MinaNassef-p6r 5 ай бұрын
Moving the layout.tsx to the locale directory, made everything else doesn't work properly in my project
@twanabrno875
@twanabrno875 4 ай бұрын
Thanks, But we can not build production it gives error with static and i can not fixt it
@survivordaqwv9002
@survivordaqwv9002 Ай бұрын
Thank you for this video! Can you make a video on RTL languages too? Would be really appreciated.
@alangiovanni5204
@alangiovanni5204 Ай бұрын
Great video! thank you vert much!
@razvlekashka
@razvlekashka 3 ай бұрын
Does redirection of homepage affects SEO?
@mohdsahil226
@mohdsahil226 7 ай бұрын
Nice tutorial! Could you please add routing. like adding about and contact page. That is giving error
@10zDelek
@10zDelek 7 күн бұрын
great video
@pamphilemkp
@pamphilemkp 7 ай бұрын
Nice tutorial though, thank you so much but sir Could you please create a second video with the app router (without the SRC) in nextjs i have tried to implement the same thing but i got some issues, please kindly create a second video i have existing app router projects that i will need to implement the translation this only works for the SRC, best regards 😊😉
@pierosabino
@pierosabino 5 ай бұрын
Good morning, I followed the video and I would like to add pages to my project, how can I do it?
@maskman4821
@maskman4821 7 ай бұрын
Sir, I have tried to implement next-intl, the only thing different is that I don't have src folder, I have app folder under root directory, I have followed the video and your github and it always led to not-found page, is there a way to get around src folder? 🤔
@Falconforex
@Falconforex 7 ай бұрын
Try to put the src files in the video in your app folder And organize the files import in i18n and middleware files
@maskman4821
@maskman4821 7 ай бұрын
​@@Falconforex OK,I will give it a try,thank you for the reply ❤
@pamphilemkp
@pamphilemkp 7 ай бұрын
i don't think it is a good idea, we have existing projects with the app router and we need to know how we can implement the translation on it@@Falconforex , i have also faced this issue
@ashishsubedi1400
@ashishsubedi1400 5 ай бұрын
bro did you found solution?
@maskman4821
@maskman4821 5 ай бұрын
@@ashishsubedi1400 nope
@ankursharma4304
@ankursharma4304 2 күн бұрын
it not working for me even though I floowed the updated doc
@ApisBackground
@ApisBackground 7 ай бұрын
So really nice tutorial dude. I have a question, is there any way to make the same with "PAGES ROUTER"?...It's because I realized that you set the language very well. And when you navigate back, it not return to last language route "/en" or route by default , it quit from the apliccations really well, and I want to achieve that behaviour. Hope your advice, Thanks a lot.
@husseinoklah8839
@husseinoklah8839 5 ай бұрын
Thank you very much for the explanation but we are still waiting second part for server side translation
@VetrivelanArasu
@VetrivelanArasu 6 ай бұрын
what if i don't have src folder.
@jaspreetmaan121
@jaspreetmaan121 5 ай бұрын
then use root folder
@eliuddyn
@eliuddyn 4 ай бұрын
Amazing 🔥🔥
@CandDev
@CandDev 3 ай бұрын
Thanks 🔥
@tomasburian6550
@tomasburian6550 2 ай бұрын
Good stuff, but I hate how you can't use multiple sententences in the namespaces. Basically they can't contain full stops, so you gotta plan around it.
@naolfekadu6101
@naolfekadu6101 3 ай бұрын
Whatif I have deeply nested routes? How would the router replace work?
@santiagomanso-b5j
@santiagomanso-b5j 3 ай бұрын
I am wondering the samething... I thought about asking chatGPT to create a function to detect the current URL path like I dont know localhost:4000/en/dashboard?userId=xjhf123fd09dslkj2123123 and the function could get a string "es | de | en" and inside that function and replace the current url param but replace the "en" for "es" or "de" on the current path for the string coming from the function.. It could be a function that could be called from anywhere and be placed inside of "src/utils/" or I'm full of bad practices haha I'm just a junior doing things for 1st time
@helloWorldPlus
@helloWorldPlus 5 ай бұрын
Hello, Which would be the importance of selecting yes for the src directory? How would be the process if I have the app with no src directory?
@rosmildolopes3985
@rosmildolopes3985 5 ай бұрын
I have the same question
@mmm-m2t
@mmm-m2t 20 күн бұрын
Bro, I'm crying, is there an option how to do all this for SSG without 100500 crutches?
@limitlesstothemoon
@limitlesstothemoon 2 ай бұрын
great sir
@jy1772
@jy1772 7 ай бұрын
When you visit the index page '/', it shows 404. How do you solve it?
@ariyansalari270
@ariyansalari270 6 ай бұрын
you should do this code in nextconfig : module.exports = { async redirects() { return [ { source: '/', destination: '/redirectRoute', permanent: true, }, ] }, }
@capK29
@capK29 6 ай бұрын
Hello Bro. I would like to request a video about redux toolkit. Learning from ur tutorial helps me alot to understand react better.
@lucaseitel98
@lucaseitel98 6 ай бұрын
Didnt next have built in i18n internationalisation?
@3litepker
@3litepker 4 ай бұрын
yes, it does
@germancardosodesousa5183
@germancardosodesousa5183 4 ай бұрын
Great video! I have a question, how could i do if i want to add another router, like app/bio/page.tsx ... I have to put it into my [locale] folder, or into app folder? Thanks!!!
@YTthings666
@YTthings666 4 ай бұрын
Nice tutorial thanks! i have a question.... How do i build a header responsive (burger menu , etc) with a "use client " ? or another solution?
@omarrayes2281
@omarrayes2281 5 ай бұрын
Thanx . Please Answer on my question .... How can make url without en . like instead of localhos/en to be localhost ?
@sengwatrongrat1630
@sengwatrongrat1630 6 ай бұрын
Hello sir, I have one question. Can useTranslations() be used in both server and client component?
@moussaibrahem9
@moussaibrahem9 3 ай бұрын
No Hooks can't be used in server side components
@RwandaBruno
@RwandaBruno 5 ай бұрын
Thanks very much ❤❤❤❤
@rokkazmvm
@rokkazmvm 3 ай бұрын
Hey, is there a way to have one language(lets say english) not have any prefix by default? And others have like shown on video?
@sandrotabatadze3768
@sandrotabatadze3768 6 ай бұрын
where should i create app directory and which files should i move in it??
@me.akaaba
@me.akaaba 5 ай бұрын
app directory is automatically created for you when you create your next app with create-next-app, it will be in src folder if you choose src during creation. otherwise in root directory if you choose to discard src during the create-next-app terminal commands.
@divyarajsinhrana6045
@divyarajsinhrana6045 5 ай бұрын
How to manage multiple middleware with different matcher config ?@Cand DEV
@luesmadev
@luesmadev 9 күн бұрын
Could you solve it? the same thing happens to me
@Mark-lg2qe
@Mark-lg2qe 6 ай бұрын
How to write middleware when joining Next-Auth
@codingspot
@codingspot 6 ай бұрын
YEEEEE same here!
@aldotugasumb2366
@aldotugasumb2366 3 ай бұрын
soo cool
@feksoftware
@feksoftware 8 ай бұрын
thanks nice tutorial. Can you teach dynamic language structure using Next.js and database? I mean like a multilingual dynamic website
@dreamsachiever212
@dreamsachiever212 8 ай бұрын
exactly. I wanted to ask the same! I have a marketplace project for multi-country and I assume it's going to be messy when i reach the implementation of internalization and localization feature
@CandDev
@CandDev 7 ай бұрын
Thanks, great idea. I'll consider it for future tutorials
@mouad3599
@mouad3599 6 ай бұрын
is this available in JS not TS
@Jeridi
@Jeridi 3 ай бұрын
amazing
@petpetai
@petpetai 2 ай бұрын
How to use next-intl in client components?
@pontingIndia
@pontingIndia 6 ай бұрын
Can we set default language without adding /en in the url.
@Happycat-xd8rw
@Happycat-xd8rw 5 ай бұрын
Bang cara agar kalau pindah halaman makek next/link, tetep di bahasa yg di select ?
@Tommy-jn9ps
@Tommy-jn9ps 6 ай бұрын
what microphone are you usin? Thanks
@amcheachamroeun2716
@amcheachamroeun2716 5 ай бұрын
Can you show when we routing like about page
@JavohirXasanov-kt6oi
@JavohirXasanov-kt6oi 6 ай бұрын
bruh can you create localization without sub-path or any routing like: /en or smth so can you provide how to create sitemap with next-intl thank you
@murazaslan3631
@murazaslan3631 4 ай бұрын
hello,how to fixed this problem ?
@ahmedadawy8149
@ahmedadawy8149 5 ай бұрын
You are very cooooooooooooooooooool
@SriramPrasanth-n9c
@SriramPrasanth-n9c 5 ай бұрын
Nice
@juanebertaypeescobar3482
@juanebertaypeescobar3482 7 ай бұрын
good video, how can I disable to not see the prefix in the url, it is causing me conflicts with another security dependency.
@gustavenzi
@gustavenzi 7 ай бұрын
I've been trying to figure out how to achieve this, but haven't found any good solutions yet
@zqgAFf
@zqgAFf 4 ай бұрын
Can you provide us a one with Next14 with clerk , the middleware seems to have a conflict
@luesmadev
@luesmadev 9 күн бұрын
Hello, were you able to solve it? I need the same
@ahmedadawy8149
@ahmedadawy8149 4 ай бұрын
I Like you really
@AhmedKhaled-mw9rs
@AhmedKhaled-mw9rs 7 ай бұрын
For not found page: export const config = { // Match only internationalized pathnames // matcher: ['/', '/(ar|en)/:path*'] matcher: '/((?!api|static|.*\\..*|_next).*)' };
@bernardukiii
@bernardukiii 5 ай бұрын
BEWARE: next-intl does NOT support 'complex' data structures. It will not let you iterate over a list for example. Not even using its useFormatter() hook.
@3litepker
@3litepker 5 ай бұрын
What’s the solution?
@Aufafkri
@Aufafkri 4 ай бұрын
Bang lu orang indo?
@CandDev
@CandDev 4 ай бұрын
iya bang. jowo tulen bang
@caioalves8319
@caioalves8319 7 ай бұрын
Can you make a video using Clerk and Next i18n?
@joscript7846
@joscript7846 7 ай бұрын
I can do that on my channel
@caioalves8319
@caioalves8319 7 ай бұрын
@@joscript7846 Please
@tuananhdo1870
@tuananhdo1870 5 ай бұрын
6:37
@RizkiRamadhan-r1j
@RizkiRamadhan-r1j 7 ай бұрын
ada indonesia coyyy
@CandDev
@CandDev 7 ай бұрын
dan orang indonesia ini emang ada dimana mana ya. 😁
@berhaneselassie7811
@berhaneselassie7811 4 ай бұрын
This video like United Nations - useless!
@nguyenvohoanglong3898
@nguyenvohoanglong3898 5 ай бұрын
So basic
@sayedalisinasadat2908
@sayedalisinasadat2908 20 күн бұрын
great , for nested layout : for ex : the third layout i have include header and navbar but not working
@murazaslan3631
@murazaslan3631 4 ай бұрын
hello,how to Removing the Default Locale ?
@niconel7659
@niconel7659 5 ай бұрын
Anyone got a working example of combining next-intl and autjs 5 (beta) in the middleware?
@luesmadev
@luesmadev 9 күн бұрын
Hello, were you able to do it? I need the same
@niconel7659
@niconel7659 8 күн бұрын
@@luesmadev Ended up going with Clerk, next-auth seems to be in beta forever. So no, sorry bud
@NursultanBegaliev
@NursultanBegaliev 4 ай бұрын
Thank you!
How Strong is Tin Foil? 💪
00:26
Preston
Рет қаралды 116 МЛН
Every parent is like this ❤️💚💚💜💙
00:10
Like Asiya
Рет қаралды 9 МЛН
The Joker wanted to stand at the front, but unexpectedly was beaten up by Officer Rabbit
00:12
Internationalization in NextJs 13
22:27
Hamed Bahram
Рет қаралды 56 М.
Internationalization (i18n) with Next.js!
9:16
leerob
Рет қаралды 55 М.
10 common mistakes with the Next.js App Router
20:37
Vercel
Рет қаралды 215 М.
Removing the Default Locale | Internationalization in NextJs 14
18:00
The Home Server I've Been Wanting
18:14
Hardware Haven
Рет қаралды 51 М.
Translate NextJS 14 with next-intl
20:13
RealLifeOverrated
Рет қаралды 1,3 М.
How Strong is Tin Foil? 💪
00:26
Preston
Рет қаралды 116 МЛН