react-native-weward-android-pedometer

1.0.6 • Public • Published

react-native-weward-android-pedometer

Getting started

$ npm install react-native-weward-android-pedometer --save

Mostly automatic installation

$ react-native link react-native-weward-android-pedometer

Manual installation

Android

  1. Open up android/app/src/main/java/[...]/MainActivity.java
  • Add import com.weward.pedometer.RNWewardAndroidPedometerPackage; to the imports at the top of the file
  • Add new RNWewardAndroidPedometerPackage() to the list returned by the getPackages() method
  1. Append the following lines to android/settings.gradle:
    include ':react-native-weward-android-pedometer'
    project(':react-native-weward-android-pedometer').projectDir = new File(rootProject.projectDir, 	'../node_modules/react-native-weward-android-pedometer/android')
    
  2. Insert the following lines inside the dependencies block in android/app/build.gradle:
      compile project(':react-native-weward-android-pedometer')
    

Usage

import RNWewardAndroidPedometer from 'react-native-weward-android-pedometer';

//Starts step service
RNWewardAndroidPedometer.startStepService();

//Stops step service
RNWewardAndroidPedometer.stopStepService();

Readme

Keywords

Package Sidebar

Install

npm i react-native-weward-android-pedometer

Weekly Downloads

0

Version

1.0.6

License

none

Unpacked Size

16.9 kB

Total Files

14

Last publish

Collaborators

  • nicolasweward