Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Abe Layee
8,378 PointsActivated scroll animation
Good day all. How are we all doing today? I have a question. How do I achieve activated scroll animation. I want my contents to fade in as you scroll down the page. I am currently looking for an article on how to this. I want to know what I need to achieve this task. I understand javaScript code pretty well. Thank you again.
2 Answers
Colin Marshall
32,861 PointsHere is a Stack Exchange post that goes over what you are trying to accomplish: Fade In on Scroll Down, Fade Out on Scroll Up
Abe Layee
8,378 PointsAlright, thank you guys. I appreciate it.
Rob Ernest
1,626 PointsRob Ernest
1,626 PointsI actually did this on my website, pretty cool effect. Assuming you're using jQuery, use the following code.
When the scroll bar reaches "thisElement" the animation will activate. You can play around with the number I have in there to help fine tune the activation point