Wilderness
an SVG animation API

Summary

  • 🎉 Small file size (15.1kb minified + gzip)
  • 🌟 Simple, functional API
  • 🐣 Morph from anything, to anything
  • ⏱️ Queue multiple animations on a timeline
  • 🚀 Powerful playback control

Hello world


import { shape, render, timeline, play } from 'wilderness'

const morph = shape(
  { el: document.querySelector('circle') },
  { el: document.querySelector('rect') },
)

const animation = timeline(morph, {
  duration: 2000,
  iterations: Infinity,
  alternate: true
})

render(document.querySelector('svg'), animation)

play(animation)