简要描述:
- 本地缓存数据,非浏览器缓存
sxclient.cache
调用权限
- 仅本地文件或素玄应用可以调用
调用方式
- 异步promise方式
请求参数:
参数名 | 是否必须 | 类型 | 说明 |
---|---|---|---|
key | 是 | string | 缓存key |
content | 否 | mix | 缓存内容,如果未传此参数,则获取参数 |
调用示例:
sxclient.cache(key,"缓存内容",30).then((res)=>{
console.log("write cache res:",res,key)
}).catch((e)=>{
console.log("write cache err:",e,key)
})
返回参数说明:
参数名 | 类型 | 说明 |
---|---|---|
string |
备注:
- 更多返回错误代码请看首页的错误代码描述
作者:宋德美 创建时间:2024-12-08 13:56
最后编辑:宋德美 更新时间:2024-12-08 14:43
最后编辑:宋德美 更新时间:2024-12-08 14:43