Scroll animation presets

Most scroll animations want the same handful of option combinations, and getting there means learning the whole option surface first. A preset is shorthand for two to four of those options, so { preset: "sketch" } is a complete setup. They are not a lock-in: anything you pass alongside a preset overrides it, so a preset is a starting point rather than a mode.

13preset · 'sketch' 'reveal' 'typewriter' …

The code

An illustration studio's portfolio. Five client pieces — a wine label, a logo, a process diagram, a hero and an app icon — each draw with a different one-word preset, and each card prints the settings that preset stands for.

Hero.tsx18 lines
import { ScrollDraw } from 'svg-scroll-draw/react';

// One word sets easing, speed, stagger and fade
<ScrollDraw preset="sketch">      {/* wine label   */}
  <svg>…</svg>
</ScrollDraw>
<ScrollDraw preset="reveal">      {/* logo, once   */}
  <svg>…</svg>
</ScrollDraw>
<ScrollDraw preset="typewriter">  {/* diagram      */}
  <svg>…</svg>
</ScrollDraw>
<ScrollDraw preset="cinematic">   {/* hero         */}
  <svg>…</svg>
</ScrollDraw>
<ScrollDraw preset="spring">      {/* app icon     */}
  <svg>…</svg>
</ScrollDraw>
Linework, an illustration and motion studio in ghent: the first screen of its demo site

An illustration and motion studio in Ghent

Linework

Live site

Related examples

Make your own in the easing visualizer: set it up, watch it run, copy the code.

MIT licensed, zero runtime dependencies. Every API is a separate entry point, so you only ship what you import. Full API reference →