Ionic2 Backgroundmode


#1

Hi,

I have created an APP and i can see there is a service also created in my mobile.

but when i kill the app from task manager it doesnt work any more.

can anyone let me know how can i keep the app running in the background mode.?

below is the piece of code under constructor method.

 platform.ready().then((readySource) => {
  console.log("Myapp::constructor platform.ready");
  BackgroundMode.setDefaults({
    title: 'notification',
    text: 'executing background task'
  })
  BackgroundMode.enable();
});  

Regards,
Navin