type AnalyticsProperties = Record; type SafeAnalytics = { capture: (event: string, properties?: AnalyticsProperties) => void; identify: (userId: string, properties?: AnalyticsProperties) => void; reset: () => void; }; const noop = () => {}; const safeAnalytics: SafeAnalytics = { capture: noop, identify: noop, reset: noop, }; export const useSafeAnalytics = (): SafeAnalytics => safeAnalytics;