I am creating an app for video calling ,I am using ionic 5 and FCM to get notification but i hvae to customize notification like an incomming call
Thanks In Advance and sorry for my bad English
`this.platform.ready().then(() => {
this.backgroundMode.enable();
this.backgroundMode.on('activate').subscribe(() => {
console.log('backgroundMode activate');
});
this.startService();
FCM.getToken().then(token => {
console.log(token);
this.storage.set('DeviceId', token);
});
// ionic push notification example
FCM.onNotification().subscribe(data => {
console.log(data);
if (data.wasTapped) {
console.log('Received in background');
this.router.navigate([data.landing_page]);
} else {
console.log('Received in foreground');
this.router.navigate([data.landing_page]);
}
});
// refresh the FCM token
FCM.onTokenRefresh().subscribe(token => {
console.log(token);
});
});
this.platform.resume.subscribe((e) => {
this.backgroundMode.enable();
});
this.authenticationService.authState.subscribe(state => {
if (state) {
this.router.navigate(['home']);
} else {
this.router.navigate(['login']);
}
});
}`