I think it might better to ask hooks related question on Stackoverflow instead of here. Like how to create an array of refs. There aren't too many people who are familiar with hooks over here.
That said, I got it to work, but I don't know if that's the best way to create an array of refs.
Stagger Animation with React Functional Components
in GSAP
Posted
Good job,