update sw.js
This commit is contained in:
parent
9b46411fa7
commit
de658f1ddd
|
@ -45,7 +45,17 @@ module.exports = class extends Component {
|
|||
var lazyLoadInstance = new LazyLoad({
|
||||
});
|
||||
</script>
|
||||
|
||||
<script>
|
||||
if ('serviceWorker' in navigator) {
|
||||
window.addEventListener('load', function () {
|
||||
navigator.serviceWorker.register('/js/sw.js').then(function (registration) {
|
||||
console.log('ServiceWorker registration successful with scope: ', registration.scope);
|
||||
}).catch(function (err) {
|
||||
console.log('ServiceWorker registration failed: ', err);
|
||||
});
|
||||
})
|
||||
}
|
||||
</script>
|
||||
</Fragment>;
|
||||
}
|
||||
};
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "hexo-theme-amane",
|
||||
"version": "0.0.29",
|
||||
"version": "0.0.30",
|
||||
"author": "Nofated095 <nofated095@users.noreply.github.com>",
|
||||
"license": "MIT",
|
||||
"description": "A simple, delicate, and modern theme for Hexo",
|
||||
|
|
Loading…
Reference in New Issue