I am having trouble understanding the docs for Facebook Login SDK
I have been trying to build an app (react for front end with typescript) that requires social media integration from various platforms, one of which is Facebook. So, I tried to follow the Meta docs and tried to implement the Facebook Login through their SDK code. The login alone was not very difficult to code, however when I refresh the page or switch to a different page and then return back to the one with the Facebook Login button, I am automatically logged out, and need to log back in every time.
I have looked through so many resources and forums trying to understand how to properly implement the Facebook login where a user can safely log in and would stay logged in throughout page refreshes until they directly click on a logout button. I feel like the Meta docs are pretty good, but the code and instructions they provide are in "pieces", if that makes sense. So, are there any full-length, detailed tutorials or guides available that I can follow along to implement this feature?
It seems the problem is not from Facebook Login , it's likely a problem with the state or the way you are saving the token granted to you after login. As long as it logs you in successfully, you should handle the received token properly for the app to be able to access it globally on each re-render.