Miss any of our Open RFC calls?Watch the recordings here! »

expo-background-fetch

4.0.0 • Public • Published

expo-background-fetch

Expo universal module for BackgroundFetch API

API documentation

Installation

This package is pre-installed in managed Expo projects. You may skip the rest of the installation guide if this applies to you.

For bare React Native projects, you must ensure that you have installed and configured the @unimodules/core package before continuing.

Add the package to your npm dependencies

npm install expo-background-fetch

Configure for iOS

Add the dependency to your Podfile and then run pod install.

pod 'EXBackgroundFetch', path: '../node_modules/expo-background-fetch/ios'

Configure for Android

  1. Append the following lines to android/settings.gradle:
include ':expo-background-fetch'
project(':expo-background-fetch').projectDir = new File(rootProject.projectDir, '../node_modules/expo-background-fetch/android')
  1. Insert the following lines inside the dependencies block in android/app/build.gradle:
api project(':expo-background-fetch')
  1. In MainApplication.java, import the package and add it to the ReactModuleRegistryProvider list:
import expo.modules.backgroundfetch.BackgroundFetchPackage;
private final ReactModuleRegistryProvider mModuleRegistryProvider = new ReactModuleRegistryProvider(Arrays.<Package>asList(
  // Your other packages will be here 
  new BackgroundFetchPackage()
)Arrays.<SingletonModule>asList());

Contributing

Contributions are very welcome! Please refer to guidelines described in the contributing guide.

Install

npm i [email protected]

Version

4.0.0

License

MIT

Unpacked Size

70.5 kB

Total Files

21

Last publish

Collaborators

  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar
  • avatar