React Redux Persist State on refresh || Keep the user logged in || Developers Diary

preview_player
Показать описание
Today we shall learn how to persist the redux state on page refresh or Keep the user logged in.

Kindly subscribe to our channel so that you can get amazing and informative videos.

#developersdiary

00:00 into
00:18 Let’s Start
00:20 Main Problem
00:34 install Redux persist
00:51 Import Persist Store and Reducer
01:20 import Storage
01:48 Mention Persist Configuration
02:18 Create Persist Reducer
02:35 Create Store using Persisted Reducer
02:47 Persist Store
03:06 export persisted Store
03:23 Import persisted Store
03:42 import Persist Gate.
04:13 Wrap your App with Persist Gate
04:59 Test the solution.
05:29 Conclusion.
Рекомендации по теме
Комментарии
Автор

Can you show me using redux persist in NextJs? Awesome video btw

real_zedd
Автор

Thanks for the tutorial, If I my project has two reducer files eg:(loginred, homereducer).how to persist login reducer file only

vinodhm
Автор

Great video!! Just a small update- Since middleware is there by default, thunk can be used as a new middleware :)

rahuljagwani
Автор

hiii, Thankyou for showing this way, but i tried this same come but, i am getting error of store.dispatch is not a function.

manalitailor
Автор

Thanks for this tutorial I have liked the video and subscribed but I have question is it safe to save user data in localStorage since I found your solution is similar to saving it in localStorage of course except password and sensitive info??

abdel-rahmanmostafa
Автор

How to remove the key in the localStorage persist:main-root - I tried with localStorage.clear() / removeItem() and nothing - how do I clear it?

etbalkics
Автор

Hello, please what is in RootReducer?

kdfconseil
Автор

@Developers Diary
how to solved this issue without installing any library???

BachelorsEntertainer
Автор

Simple, concise and straight to the point. Pure gem

theartisticjs