Skip to content

Commit

Permalink
fix linter
Browse files Browse the repository at this point in the history
  • Loading branch information
Yixin Hu committed Jan 23, 2024
1 parent 2ad7026 commit c9a8b19
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/components/FillArrow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,14 @@ function useIsInViewport(ref) {
}

function FillArrow(props: FillArrowProps): JSX.Element {
const { text1, text2, noAnimation } = props;

const ref = useRef(null);

const isInViewport = useIsInViewport(ref);

const [animate, setAnimate] = useState(false);

useEffect(() => {
if (isInViewport && !animate && !noAnimation) setAnimate(true);
if (isInViewport && !animate && !props.noAnimation) setAnimate(true);
}, [isInViewport, animate]);

return (
Expand Down

0 comments on commit c9a8b19

Please sign in to comment.