3 Replies Latest reply on Jun 2, 2017 12:35 PM by kerrishotts

    Running background service




      I'm kind of new to Phonegap.

      I have built an app using Phonegap to record and retrieve data.

      Client wants to use the app in offline mode as well, so the app needs retrieve the data when it's online.

      Since the data is pretty big we wanted to retrieve the data in the background.

      I tried to use "cordova-plugin-background-app" this plugin but it seems like the code i implanted is not recognized at all.


      I have added this in the config.xml

      <plugin name="cordova-plugin-background-service" source="npm" />


      and in the index.js I added following code just to see it is working or not


                  function(fn) { alert('started'), fn && fn() },

                  function() { alert('err') }



      However even the err is not triggering.

      is there anything I missed or is there better way to retrieve the data?