@soreine/react-native-begin-background-task
TypeScript icon, indicating that this package has built-in type declarations

0.1.1 • Public • Published

@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)

Package Sidebar

Install

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

Weekly Downloads

132

Version

0.1.1

License

MIT

Unpacked Size

13.4 kB

Total Files

10

Last publish

Collaborators

  • soreine