Pick an example or edit the schema JSON below. The animation updates in real-time.
import { createAnimation } from 'loopkit';
const anim = createAnimation(document.getElementById('cover'), {
width: 460,
height: 280,
background: '#f0fdf4',
stagger: 0.3,
trigger: 'autoplay',
hold: 2,
elements: [
{
type: 'rect',
style: { x: 40, y: 40, width: 200, height: 80, fill: '#34d399', rx: 8 },
animate: {
width: [0, 200],
opacity: [0, 1],
sequence: 0,
duration: 0.6,
easing: 'ease-out',
},
},
],
});Rectangles, lines, bars, progress indicators. Supports rx for rounded corners.
SVG text with fontSize, color, fontWeight, textAnchor. Color maps to fill.
Circles with cx, cy, r. Supports scale animation that multiplies the radius.
Composite element: shape + centered text. Circle or pill (isLabel). Scale animates the group.
Declarative JSON schema defines elements and keyframes. No imperative animation code.
Pure TypeScript, under 5KB minified. No React, no framework lock-in.
Starts at final frame, fades out before restarting, settles smoothly on hover leave.
Autoplay loops infinitely. Hover loops while hovered, settles on leave.
renderToString() outputs SVG at final frame. No DOM needed.
Hex color animation with RGB lerp. Detected automatically from # prefix.
import { createAnimation } from 'loopkit';
import { useEffect, useRef } from 'react';
function AnimatedCover({ schema }) {
const ref = useRef(null);
useEffect(() => {
if (!ref.current) return;
const anim = createAnimation(ref.current, schema);
return () => anim.destroy();
}, [schema]);
return <div ref={ref} className="w-full aspect-3/2" />;
}Write a plain JS/JSON object with canvas dimensions, element types (rect, text, circle, badge), and animation keyframes.
Pass a DOM container and your schema. The engine creates an SVG, applies the final frame immediately (no flash), and starts playback.
Use play(), pause(), reset(), settle(), and destroy() to control the animation lifecycle. Trigger modes handle autoplay and hover automatically.
Loopkit follows a declarative model: you define what elements look like and how they animate, the engine handles rendering and timing. Each element has a style (resting state) and an optional animate config with [from, to] keyframe pairs. The engine interpolates between values using requestAnimationFrame.
Each tool works standalone, runs entirely in your browser, and requires no signup.
Varstatt is a one-person product studio run by Jurij Tokarski, product engineer since 2011. These tools are free and open — no signup, no catch.