Closed trevorosborne1989 closed 2 months ago
Check this youtube out click here
Working with cookies in react. Look at this website
Also, check more about Cookies api here.
Mess around and see what data you can take from the set cookie and use as a conditional to access certain pages. You can already limit the service endpoints easily on the server side. Page navigation will be done on the ui using the cookie.
I'm not sure what data user wise you can pull from the cookie but I think you really only need to verify the condition if a cookie is set or not. Just having one set indicates this user has full access for nchandi business logic. They should be able to access every page in the ui conditionals. You can secure endpoints in the service if you like with the example you already have.
Add a logout button.
Spring is setting SecurityContextHolder to authenticated then back to anonymous, so when I go to retrieve details its null. Ask this question.