This project was generated with Angular CLI version 17.3.3.
Run ng serve
for a dev server. Navigate to http://localhost:4200/
. The application will automatically reload if you change any of the source files.
To connect FCM we are using the latest Version of AngularFire check https://github.com/angular/angularfire/blob/main/docs/messaging.md
Service Worker for Notifications Webservice to Process Notification Content when App is loaded
-
fill new Firebase Information in app.module.ts Service Worker
-
run
ng build
ng serve
- copy fcm token from console
my fcm token f8Xlr_Nho0ylT_GDNtE7ek:APA91bH5OvTthJo8-TKlpuYG3JgcqhiY_IyRbpwmuST2uzGlrIXYQaqIGy1j2wGM6dSzgMQIfkGWXLvOiCoERUKgQ0bW2Ego4S5zN9KavsyYC70YlmDM2iQ
-
send testmessage via https://console.firebase.google.com/project/{{your project id}}/notification/compose
-
check for
[firebase-messaging-sw.js] Received background message:
in console.
- If no Popup appears check Popup Settings on OS. (I wasted 4 hours because I forgot I disabled popups from all browsers.)