tubbly-capacitor-pedometer
v0.0.4
Published
Capacitor pedometer
Downloads
2
Maintainers
Readme
capacitor-pedometer
Capacitor pedometer
Install
npm install capacitor-pedometer
npx cap syncAPI
startCounting()
startCounting() => Promise<void>Starts counting steps. On iOS, this will start monitoring for pedometer updates. On Android, this will register a sensor listener for the step counter.
stopCounting()
stopCounting() => Promise<void>Stops counting steps. On iOS, this will stop monitoring pedometer updates. On Android, this will unregister the sensor listener.
getStepCount()
getStepCount() => Promise<{ count: number; }>Gets the current step count since startCounting() was called,
or since the device was last rebooted/sensor reset on Android,
or since the start of the day on iOS (depending on implementation).
Returns: Promise<{ count: number; }>
