Capacitor pedometer
npm install @tubbly/tubbly-capacitor-pedometerCapacitor pedometer
``bash`
npm install capacitor-pedometer
npx cap sync
* startCounting()
* stopCounting()
* getStepCount()
`typescript`
startCounting() => Promise
Starts counting steps.
On iOS, this will start monitoring for pedometer updates.
On Android, this will register a sensor listener for the step counter.
--------------------
`typescript`
stopCounting() => Promise
Stops counting steps.
On iOS, this will stop monitoring pedometer updates.
On Android, this will unregister the sensor listener.
--------------------
`typescript`
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; }>
--------------------