Function: useOnDeviceOrientation()
useOnDeviceOrientation(
callback): (() =>void) |null
Defined in: src/infrastructure/sensors/sensors.service.ts:229
Listens for device orientation events (compass heading, tilt).
Parameters
callback
(event) => void
Called with each DeviceOrientationEvent.
Returns
(() => void) | null
A cleanup function that removes the listener, or null if unavailable.
Example
const off = useOnDeviceOrientation((e) => {
console.log("Alpha:", e.alpha);
});