Background service to trigger local notification

I want to trigger local notification whenever the device connected to internet. It works fine if the app is in background but need to set the service even if the app is killed.

https://ionicframework.com/docs/native/background-mode/ doesn’t works if the app is killed.

https://ionicframework.com/docs/native/local-notifications/ provides triggers notification even if the app is killed for timer and geo location.

Same like I want to trigger notification whenever the device connected to internet even if the app is closed.