--- layout: default title: Animate In Demo description: When elements enter the viewport, they transition in from zero opacity and from the bottom. image: /demos/animated.jpg prism: true externalJS: [ "https://unpkg.com/intersection-observer" ] extraJS: [ "demos/animate-in.js" ] ---
This was inspired by codrops’ demo Loading effects for grid items with css animations.
IntersectionObserver
is used to determine when the elements enter the viewport. A polyfill is included on the page for browsers which don't support it.