Skip to content

Commit

Permalink
Minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
tanish35 committed Oct 14, 2024
1 parent 6914197 commit 764edcc
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions frontend/src/components/homePage/HomePage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,6 @@ export const Header = () => {
const navigate = useNavigate();
const { loadingUser, userDetails } = useUser();

if (loadingUser) {
return (
<div className="flex justify-center items-center h-screen">
<InfinitySpin color="#6366F1" />
</div>
);
}

useEffect(() => {
gsap.to(".first-page-image", {
y: -100,
Expand Down Expand Up @@ -57,7 +49,15 @@ export const Header = () => {
}
);
});
}, []);
}, [loadingUser]);

if (loadingUser) {
return (
<div className="flex justify-center items-center h-screen">
<InfinitySpin color="#6366F1" />
</div>
);
}

return (
<div className="bg-[#1F2135]">
Expand Down

0 comments on commit 764edcc

Please sign in to comment.