uni-app 数据本地存储
uni-app About 296 words同步方法
uni.setStorageSync('storage_key', 'hello');
异步方法
uni.setStorage({
key: 'storage_key',
data: 'hello',
success: function () {
console.log('success');
}
});
读取
const value = uni.getStorageSync('storage_key');
参考文档
Views: 23 · Posted: 2025-07-29
————        END        ————
Give me a Star, Thanks:)
https://github.com/fendoudebb/LiteNote扫描下方二维码关注公众号和小程序↓↓↓

Loading...