Get Notification Even app is killed

How to receive a notification when the app is killed, Notification is sending through payload from the server-side.

So I have to read the payload data nad need to show notification by using local notifications in ionic and angular. So am unable to understand how to receive payload data or on which callback I have to use payload data. am not understanding.

I am using cordova-plugin-fcm for receiving notifications. am able to get notifications when the app is in forground, by using, fcm.onNotification()-am reading data here and showing localnotification