fix(pwa): re-enable Workbox precaching (remove if guard and injectionPoint override)

This commit is contained in:
Evie Gauthier committed 2026-04-06 12:35:25 -04:00
1 parent 8d5521598d
commit 202567bf05
2 files changed
+6 -4

No files matched your search

+1 -3
View File
@@ -902,7 +902,5 @@ self.addEventListener('notificationclick', (event: NotificationEvent) => {
);
});
if (self.__WB_MANIFEST) {
precacheAndRoute(self.__WB_MANIFEST);
}
precacheAndRoute(self.__WB_MANIFEST);
cleanupOutdatedCaches();
+5 -1
View File
@@ -176,7 +176,11 @@ export default defineConfig(({ command }) => ({
injectRegister: false,
manifest: false,
injectManifest: {
injectionPoint: undefined,
// element-call is a self-contained embedded app; exclude its large assets
// from the SW precache manifest (they are not part of the Sable shell).
globIgnores: ['public/element-call/**'],
// The app's own crypto WASM and main bundle exceed the 2 MiB default.
maximumFileSizeToCacheInBytes: 10 * 1024 * 1024, // 10 MiB
},
devOptions: {
enabled: true,