rn-sensors
v1.0.5
Published
A package to obtain data for sensors in react-native
Downloads
3
Readme
Supported React Native Versions
React Native >= 0.40
Documentation
Installation
yarn add rn-sensors
cd ios && pod install && cd ..
Usage
import { getData, startUpdates, stopUpdates } from 'rn-sensors'
useEffect(() =>{
startUpdates()
return () => stopUpdates()
},[])
//when you want to obtain data from the sensors.
getData((error, result) => console.log('result', result))
Credits
This project is inspired by the react-native-sensors