removeStorage

解释:从本地缓存中异步移除指定 key。

参数:Object

Object参数说明:

参数类型必填说明
keyString本地缓存中的指定的 key
successFunction接口调用成功的回调函数
failFunction接口调用失败的回调函数
completeFunction接口调用结束的回调函数(调用成功、失败都会执行)

示例:

  1. swan.removeStorage({
    key: 'key',
    success: function (res) {
    console.log(res);
    },
    fail: function (err) {
    console.log('错误码:' + err.errCode);
    console.log('错误信息:' + err.errMsg);
    }
    });