uniapp清除所有缓存

使用场景:退出登录的时候解绑之后清除所有缓存 

 uni.clearStorageSync();

	 uni.showModal({
						        title: "提示",
						        content: "确定要退出登录吗?",
						        success: (res) => {
						          if (res.confirm) {
									  uni.showToast({
									  	title:res.Message,
									  	icon:"none"
									  })
						         uni.clearStorageSync();
						            uni.reLaunch({
						              url: "/pages/wechatAuthorization/wechatAuthorization"
						            });
						          }
						        }
						      });

你可能感兴趣的:(uniapp微信小程序相关,uni-app,缓存,java)