1

i have got web project using mern stack where i store the jwt as an http only cookie, so that when user authenticates themselves, it is not required to pass the token as a header.

however, i will also be building the mobile version of this project in the future using react native, as http only cookie system doesnt work for the mobile, what can i do now?

is storing jwt in the localstorage and passing it in the header the only alternative? or are there other ways where i could still use http only cookie system in the web, and use some other alternatives for app, and still have the same backend overall. looking for the feedbacks and guidance

asked May 31, 2024 at 14:36
1
  • Can you describe what is not working ? Why can't just use lcoalstorage ? Commented Jun 2, 2024 at 12:41

0

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.