my.removeStorage
Remove cached data.
This is an asynchronous interface.
Removing the webview embedded storage data will not remove the storage data of the Mini Program.The cached data are user isolated, which means if user logs out wallet and logs in as a different user, the mini program will not be able to get previous user's cached data.
Sample Code
copy
my.removeStorage({
key: 'currentCity',
success: function(){
my.alert({content: 'remove success'});
}
});
Parameters
Name | Type | Mandatory | Description |
---|---|---|---|
key | String | Yes | Cache data key |
success | Function | No | Callback function upon call success |
fail | Function | No | Callback function upon call failure |
complete | Function | No | Callback function upon call completion (to be executed upon either call success or failure) |