How to add Redux to ANY Next.js app in 15 minutes (For Beginners)

preview_player
Показать описание


🔴 LOOKING FOR THE CODE? 🛠️

👇🏻FOLLOW ME HERE:

💰 WANT TO SUPPORT THE CHANNEL?

🕐 TIMESTAMPS:
00:00 Introduction
00:19 SkillShare Sponsorship
02:54 Adding Redux & Setting up the Store
04:13 Wrapping App in a Redux Provider
05:38 Creating our First Redux Slice
08:48 Importing Counter Slice to the Store
09:29 Starting the App & Debugging with Redux Devtools
10:24 Adding our first Selector with the useSelector Hook
11:50 Adding Buttons to Dispatch Actions with the useDispatch Hook
12:36 Testing our App built with Redux!
13:32 Bonus Tip: How to correctly write a Selector
14:38 Outro

Let’s get it PAPAFAM 🔥.

#reactjs #nextjs #redux
Рекомендации по теме
Комментарии
Автор

he makes this so easy !! keep going man

cyberstair
Автор

Excellent description of Redux. I’ve been confused by all of the ‘jargon’ that surrounds Redux but you explained it in simple terms. Well done

stevenwoolston
Автор

I prefer the long form clone series, but little focus videos like this are very useful to supplement the long form. Great video man, thanks.

jonjojr
Автор

Briefly, clearly, qualitatively. Keep it up!

swayze_
Автор

I just can't believe the quality of your content. Amazing!

Brenosalv
Автор

Redux store gets wiped out with NextJS SSR from one page to another. You can't simply use React Redux in a one page app and assume it'll work for most NextJS projects. You can't simply use your react tools with NextJS!✋

zacpour
Автор

Please Sir bring your 5 day event soon!! Truly missing them very much.. Those were golden times.. Although I could never submit the code as I couldn't follow up but now I have evolved and will surely prove to be among the ones who get featured 💥💥

#PapaFam
#PapaReact
#SonnySangha

divyam
Автор

So we are 1) server-side rendering our apps, 2) serving them to the clients, 3) the clients run some JS and setup a state manager that runs on the client, 4) User navigates to another route, which causes our store to be reset no? I'm having a really hard time understanding this architecture

Euquila
Автор

I been doing it this way for awhile, it's easier than the old way I was doing it.

apacolypse
Автор

omg, I'm grateful to be able to meet this channel soon. U explained so well. Thanks ^^

tarisadindadeliyanti
Автор

Could you plz at least once post a video on how a NEXT app can be deployed to AWS ? How do the SSG and SSR work there does it mean SSR is gonna work in A lamda ?

sourenasahraian
Автор

thanks bro, this is exactly what i was looking for.

ahmadshbeeb
Автор

Thank you. I got the counter equal to zero. I noticed this after examining it with redux tools.

John-wxzn
Автор

Amazing!! Clean and Clear!!! I was a redux hater. Since the redux toolkit release, I will use redux as my state management tool again, thx Sonny!

generallifing
Автор

when page is serverSide rendered can we use this to update redux store ??

dream__moments
Автор

Hey Sonny!
Can you help us understand, how does nextJS plays with Redux when using server side props and static side props,
Example, if we have a redux action that hits an API should we do this in server side props? Or is this something we don't have to worry about

carlopelosi
Автор

hi Sonny, which screen recording software do you use?

hmaina
Автор

can you update this tutorial with the latest next js version please

UpdaterMC
Автор

Awesome ! quick lesson but very straight to the point !!
Now I get to know Mr. Redux even better.
Thanks Sonny !

PattySpicy
Автор

you're awesome,
could you have a video with redux and server side rendering in next js.
It is a bit confusing.

amirbasiri