Skip to content

Soreine/react-native-begin-background-task

 
 

Repository files navigation

@soreine/react-native-begin-background-task

⚠️ Note: This only works on iOS and will be ignored on other platforms.

Installation

npm i @soreine/react-native-begin-background-task

then...

npx pod-install

Usage

import { beginBackgroundTask, endBackgroundTask } from '@soreine/react-native-begin-background-task';

// ...

const backgroundTaskId = await beginBackgroundTask();

// Your task that you want to keep running if the app goes to the background...

await endBackgroundTask(backgroundTaskId)

About

React Native wrapper for beginBackgroundTask, iOS only

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Objective-C 54.6%
  • Ruby 23.5%
  • JavaScript 21.9%