UNPKG

unified-analytics

Version:

Unified analytics library for web applications

15 lines (14 loc) 763 B
import { EventAttributes } from '../types'; /** * Custom hook to track screen duration * @param screenName - The name of the screen/event to track * @param additionalAttributes - Additional attributes to include with the analytics event */ export declare const useScreenDuration: (screenName: string, additionalAttributes?: EventAttributes) => null; /** * Custom hook to track scroll depth * @param eventName - The name of the event to track when scrolling * @param throttleMs - Throttle time in milliseconds (default: 500ms) * @param additionalAttributes - Additional attributes to include with the analytics event */ export declare const useScrollDepthTracking: (eventName: string, throttleMs?: number, additionalAttributes?: EventAttributes) => null;