我实现了一个服务工作者。我看起来很不错,激活没有错误,...
但我看不到那里的东西:
sw.min.js:
workbox.routing.registerRoute(
({request}) => request.destination === 'style',
new workbox.strategies.NetworkFirst({
// cacheName: cacheNamecss,
plugins: [
new workbox.expiration.ExpirationPlugin({
maxEntries: 20,
maxAgeSeconds: 7 * 24 * 60 * 60
}),
new workbox.cacheableResponse.CacheableResponsePlugin({
statuses: [0, 200],
headers: {'X-Is-Cacheable': 'yes'}
})
]
}));
这是在Google Chrome's
Application
->Service Workers