Skip to content

Commit

Permalink
feat: allow configure falsy navigate fallback (#70)
Browse files Browse the repository at this point in the history
  • Loading branch information
userquin committed Nov 13, 2023
1 parent d94c654 commit dc4e929
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@vite-pwa/sveltekit",
"type": "module",
"version": "0.2.7",
"packageManager": "pnpm@8.8.0",
"packageManager": "pnpm@8.10.3",
"description": "Zero-config PWA for SvelteKit",
"author": "antfu <anthonyfu117@hotmail.com>",
"license": "MIT",
Expand Down
3 changes: 2 additions & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ export function configureSvelteKitOptions(
}
else {
options.workbox = options.workbox ?? {}
if (!options.workbox.navigateFallback)
// the user may want to disable offline support
if (!('navigateFallback' in options.workbox))
options.workbox.navigateFallback = adapterFallback ?? base

config = options.workbox
Expand Down

0 comments on commit dc4e929

Please sign in to comment.