OVA â On View Animations
OVA is a lightweight JavaScript library that animates HTML elements as they enter the viewport. It requires no dependencies and is built on the native IntersectionObserver API.
How it worksâ
Add a data-ova attribute to any HTML element. When that element scrolls into view, OVA automatically triggers its animation. No JavaScript configuration required â everything is controlled via HTML attributes.
<div data-ova="animation: fade-top; duration: 800ms; delay: 200ms">
<h1>Hello World</h1>
</div>
Featuresâ
- ðŠķ Lightweight â one JS file and one CSS file, no dependencies
- ⥠Performant â uses
IntersectionObserverand stops observing after the animation fires - ðĻ Customizable â control animation, duration, easing, delay and offset per element
- ð Flexible â available as Vanilla JS bundle, ESM with bundled CSS, or ESM with separate CSS
- âïļ Extensible â add your own custom animations with plain CSS
Browser supportâ
OVA relies on the IntersectionObserver API, which is supported by all modern browsers. Internet Explorer is not supported.
Licenseâ
OVA is released under the MIT License.