Closed mark9804 closed 1 year ago
同时在设置中提供卸载选项
if ('serviceWorker' in navigator) { navigator.serviceWorker.getRegistrations() .then(function(registrations) { for(let registration of registrations) { registration.unregister(); } }); } location.reload(true);
重构先不着急, 先把游戏做了, 有新 ue 了我们再启动重构规划
SW 会拦截请求,我的想法是给用户大约一个月缓冲期从页面上注销掉 sw
同时在设置中提供卸载选项