@capgo/capacitor-pedometer
Overview
Section titled “Overview”@capgo/capacitor-pedometer streams step counts and motion metrics for fitness and wellness features. iOS can return historical ranges with distance, pace, cadence, and floors from Core Motion. Android uses the hardware step counter sensor.
Platform support
Section titled “Platform support”| Platform | Support |
|---|---|
| iOS | Core Motion, richer metrics |
| Android | Step sensor live updates |
| Web | No |
Core Capabilities
Section titled “Core Capabilities”getMeasurement- Get pedometer measurements for a specified time range.isAvailable- Check which pedometer features are available on this device.startMeasurementUpdates- Start receiving real-time pedometer measurement updates.stopMeasurementUpdates- Stop receiving real-time pedometer measurement updates.
Public API
Section titled “Public API”| Method | Description |
|---|---|
getMeasurement | Get pedometer measurements for a specified time range. |
isAvailable | Check which pedometer features are available on this device. |
startMeasurementUpdates | Start receiving real-time pedometer measurement updates. |
stopMeasurementUpdates | Stop receiving real-time pedometer measurement updates. |
checkPermissions | Check permission to access pedometer data. |
requestPermissions | Request permission to access pedometer data. |
addListener | Called when a new pedometer measurement is received. |
removeAllListeners | Remove all listeners for this plugin. |
getPluginVersion | Get the native Capacitor plugin version. |
Source Of Truth
Section titled “Source Of Truth”This reference is synced from src/definitions.ts in capacitor-pedometer.
Keep going from @capgo/capacitor-pedometer
Section titled “Keep going from @capgo/capacitor-pedometer”If you are using @capgo/capacitor-pedometer to plan native plugin work, connect it with Using @capgo/capacitor-pedometer for the native capability in Using @capgo/capacitor-pedometer, Capgo Plugin Directory for the product workflow in Capgo Plugin Directory, Capacitor Plugins by Capgo for the implementation detail in Capacitor Plugins by Capgo, Adding or Updating Plugins for the implementation detail in Adding or Updating Plugins, and Ionic Enterprise Plugin Alternatives for the product workflow in Ionic Enterprise Plugin Alternatives.