Can we use localstorage on the native Jira Cloud apps?

Hi!
My app uses the localstorage browser API to save authentication tokens.
However, it appears that this is not working when my app runs inside the Jira Cloud native apps. Is there a solution for this?

Thanks!