Replies: 1 comment 1 reply
-
Getting the same trouble with a very similar approach. How did you solved out your problems? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I handle authentication using JWT, and at the moment I have a (I think horrid) method in my _App.js which takes the cookie and loads it back into the Application, but I am now approaching a point where the site is nearing a release and the next build command gives me this warning.
Now I have just finished rewriting all my components to use hooks, using the latest nextjs and material-ui but this redux for auth is still something I struggle to get my head around, whereas hooks took me a day or two to understand migrate to.
Is there any advantage of using redux over context when my intention is only to store and persist the user token and perhaps a couple of fields?
My _App.js has this code which I feel I hate;
I just feel this is a bad technical choice, can anyone point me in a better direction?
Beta Was this translation helpful? Give feedback.
All reactions