react-native-sensor-data

1.1.3 • Public • Published

react-native-sensor-data

Getting started

$ npm install react-native-sensor-data --save

Mostly automatic installation

$ react-native link react-native-sensor-data

Manual installation

iOS

  1. In XCode, in the project navigator, right click LibrariesAdd Files to [your project's name]
  2. Go to node_modulesreact-native-sensor-data and add RNSensorData.xcodeproj
  3. In XCode, in the project navigator, select your project. Add libRNSensorData.a to your project's Build PhasesLink Binary With Libraries
  4. Run your project (Cmd+R)<

Android

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

Windows

Read it! :D

  1. In Visual Studio add the RNSensorData.sln in node_modules/react-native-sensor-data/windows/RNSensorData.sln folder to their solution, reference from their app.
  2. Open up your MainPage.cs app
  • Add using Sensor.Data.RNSensorData; to the usings at the top of the file
  • Add new RNSensorDataPackage() to the List<IReactPackage> returned by the Packages method

Usage

import RNSensorData from 'react-native-sensor-data';
 
// TODO: What to do with the module?
RNSensorData;

Readme

Keywords

Package Sidebar

Install

npm i react-native-sensor-data

Weekly Downloads

1

Version

1.1.3

License

none

Unpacked Size

670 kB

Total Files

112

Last publish

Collaborators

  • perfe