import React from "react";
import { Navigate, Outlet, useLocation } from "react-router-dom";
import { useAuth } from "../contexts/AuthContext";
export const PrivateRoute: React.FC = () => {
const { isAuthenticated } = useAuth();
const location = useLocation();
return isAuthenticated ? (
) : (
);
};