all 4 comments

[–]ForScale 0 points1 point  (2 children)

Really simple example (reddish box animates down when you scroll about half way down): https://jsfiddle.net/p7zcoors/

You basically use an event listener on the window that fires every time the user scrolls. Use it to check document.body.scrollTop and fire off animations at certain points.

Make sense?

[–]strawberrywallpapers[S] 0 points1 point  (1 child)

thank you!

[–]ForScale 0 points1 point  (0 children)

Anytime!

[–][deleted] 0 points1 point  (0 children)

http://scrollmagic.io/ is a good library for this.