/**
 * useAuth Hook
 * Auth context hook - separated for Fast Refresh compatibility
 */

import { useContext } from "react";
import { AuthContext } from "./AuthContext";

/**
 * Hook to use auth context
 */
export const useAuth = () => {
  const context = useContext(AuthContext);
  if (context === undefined) {
    throw new Error("useAuth must be used within an AuthProvider");
  }
  return context;
};

