gpt4 book ai didi

react-native - 如何在 native react 中存储 token ?

转载 作者:行者123 更新时间:2023-12-03 14:40:38 24 4
gpt4 key购买 nike

我以前在 android 中开发,我曾经使用共享首选项来存储用户 token 。对于 ios 和 android 来说,react native 中是否有这样的可用内容?

最佳答案

您可能想使用 AsyncStorage

AsyncStorage现在已弃用。您可以使用 https://github.com/react-native-community/async-storage

编辑:

对于指出 AsyncStorage 不安全的每个人,请参阅此 post .

关于react-native - 如何在 native react 中存储 token ?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50404239/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com