Utility function for finding out if the application is in the background or not
$ npm install --save cordova-is-background
import isBackground from 'cordova-is-background';
if (isBackground()) {
notify('you have a new message!');
}
See the LICENSE file for license rights and limitations (MIT).