I have a Next.js Application and for State Management I am using Redux Toolkit. Now, to maintain authentication status in frontend side, I need to take the existing token and send it to backend for validation. If I get a success Response from backend then I want to initialize my Redux store with {isAuthenticated: true} else {}. How would I achieve such thing.
I have explored other options but Nothing seem to provide satisfying and efficient answer.