EasyFrame

- Build sprite sheet animation | originally from AnimeCursor

About EasyFrame

EasyFrame is a lightweight JavaScript library that brings sprite sheet animations to your web projects with zero manual CSS coding. Simply include the library, add a few data attributes to your HTML elements, and EasyFrame automatically generates and injects the required @keyframes and class rules.

How It Works

After loading easyframe.js, any element with the class ef-sprite and a data-ef attribute will be animated. The data-ef attribute defines the sprite size, frame count, duration, and animation mode. Optionally, use data-ef-src to set the background image.

<div class="ef-sprite" data-ef="size:64x64;frames:6;duration:1;mode:loop" data-ef-src="/images/character.png"></div>

No need to write a single line of CSS – the library handles everything, even complex multi‑segment animations.

Key Features

Use Cases

EasyFrame was born from the AnimeCursor project. What started as a personal tool for generating CSS quickly evolved into a full‑fledged library to help developers skip the tedious part of sprite animation. No more manual keyframe percentages – just describe your sprite and let EasyFrame do the rest.