Permalink
Browse files

fix: offlinePage syntax error

  • Loading branch information...
galvez committed Aug 24, 2018
1 parent 261cfaf commit af21d7401a9f28932ed98a08cdf2363a708e6777
Showing with 3 additions and 3 deletions.
  1. +2 −2 package.json
  2. +1 −1 packages/workbox/templates/sw.template.js
@@ -4,8 +4,8 @@
"private": true,
"contributors": [
"Pooya Parsa <pooya@pi0.ir>",
"manniL <hello@lichter.io>",
"galvez <jonasgalvez@gmail.com>"
"Alexander Lichter <hello@lichter.io>",
"Jonas Galvez <jonasgalvez@gmail.com>"
],
"scripts": {
"test": "npm run lint && jest",
@@ -19,7 +19,7 @@ workbox.routing.registerRoute(new RegExp('<%= r.urlPattern %>'), workbox.strateg
const strategy = workbox.strategies.staleWhileRevalidate()
workbox.routing.registerRoute(new RegExp('/.*'), ({event}) => {
return strategy.handle({event})
.catch(() => caches.match('<%= options.offlinePage %>')
.catch(() => caches.match('<%= options.offlinePage %>'))
})<% } %>
<% if (options.routingExtensions) { %><%= options.routingExtensions %><% } %>

0 comments on commit af21d74

Please sign in to comment.