fix legacy service-worker issue

This commit is contained in:
toni
2025-12-24 14:58:17 +01:00
parent c7d53c88bc
commit 135c7bf4ba
15 changed files with 145 additions and 25 deletions
+5
View File
@@ -33,6 +33,7 @@ import {
MAT_DATE_LOCALE,
} from '@angular/material/core';
import { MAT_FORM_FIELD_DEFAULT_OPTIONS } from '@angular/material/form-field';
import { provideServiceWorker } from '@angular/service-worker';
import { de } from 'date-fns/locale';
import { routes } from './app.routes';
import { initializeApi } from './util/api';
@@ -88,5 +89,9 @@ export const appConfig: ApplicationConfig = {
},
{ provide: MAT_DATE_FORMATS, useValue: MAT_DATE_FNS_FORMATS },
{ provide: MAT_DATE_LOCALE, useValue: de },
provideServiceWorker('ngsw-worker.js', {
enabled: !isDevMode(),
registrationStrategy: 'registerWhenStable:30000',
}),
],
};