aos
aos copied to clipboard
Element with AOS animation created by intersection observer doesn't trigger
I have an element that is created by an intersection observer. The observer creates the element then appends it to the body and adding the aos "fade-in function as well as the duration. AOS doesn't seem to trigger the element (most likely because it was created after my intersection observer fires which is what AOS uses itself to detect intersections).
An older version doesn't have the problem (as far as I can tell), but it doesn't have scroll-past exit animations.
Is there a way to implement a feature that detects if the element AOS is listening to is already in the screen's view?
This will be much appreciated.