"use client";

import { type ReactNode,useEffect } from "react";

import { analyticsService } from "@/services/analytics";

interface AnalyticsProviderProps {
  children: ReactNode;
}

/**
 * Analytics Provider Component
 *
 * Initializes analytics service with user data when the app loads.
 * Provides analytics context to the entire application.
 */
export function AnalyticsProvider({ children }: AnalyticsProviderProps) {
  useEffect(() => {
    // Initialize analytics service
    analyticsService.initialize();
  }, []);

  return <>{children}</>;
}
