Skip to content

Commit

Permalink
Don't explode without BASE_URL
Browse files Browse the repository at this point in the history
  • Loading branch information
microbit-matt-hillsdon committed May 30, 2024
1 parent 70b60e9 commit 010d014
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export default defineConfig(({ mode }) => {
// This requires the corresponding service-worker-allowed header to be set.
// URLs are prefix matched so it's a compromise solution that could affect other
// paths sharing the same prefix
scope: process.env.BASE_URL.replace(/\/$/, ""),
scope: process.env.BASE_URL?.replace(/\/$/, ""),
workbox: {
cacheId: pwaCacheId,
// Only precache language assets for the fallback language.
Expand Down

0 comments on commit 010d014

Please sign in to comment.