morphicons is a zero-dependency library that morphs any stroke-based icon into any other using spring physics, with rotations emerging automatically from 2D Procrustes alignment and polar interpolation.

Stars

24

7-day growth

No data

Forks

0

Open issues

0

License

MIT

Last updated

2026-08-01

AI repository intelligence
FR-AI / ANALYSIS

Why it is worth attention

It eliminates hand-declared rotation groups and per-pair keyframes by solving optimal similarity in closed form, while keeping the core DOM-free, offering React, DOM, and pure-core APIs with strong performance and small bundle sizes.

Who it is for

  • React developers building animated icon systems or UI components
  • Frontend engineers using Lucide, Tabler, Heroicons, or Iconoir
  • Design-system maintainers wanting drop-in animated icons
  • Motion/UI developers needing gesture- or scroll-driven icon transitions

Use cases

  • Animated hamburger-to-close menu buttons
  • Spring-physics icon transitions in navigation and toolbars
  • Gesture- or scroll-scrubbed icon morphs via controlled progress
  • Cross-library icon morphs on a shared 24×24 grid

Strengths

  • No hand-declared rotation groups; Procrustes alignment detects rotation automatically
  • Zero runtime dependencies with no per-frame numeric allocation and small gzip footprint
  • Drop-in React replacement for lucide-react with SSR and reduced-motion support
  • Core is DOM-free, enabling React, vanilla DOM, and future React Native adapters from one package

Considerations

  • Only stroke-drawn icons morph correctly; filled or outline-filled glyphs parse but look wrong in transit
  • Icon data must be literal path/node lists without transforms, and endpoints must share a coordinate space or use fitIcon
  • ESM-only, with React as an optional peer dependency requiring React >=18

README quick start

Usage

Description

Any icon morphs into any other — universal morphing for stroke-based icons with spring physics. Zero dependencies, ~6 KB gzip.

Related repositories

Similar projects matched by category, topics, and programming language.

NUber-dev
Featured
NUber-dev GitHub avatar

YTubic

YTubic is a fast, responsive, open-source YouTube Music desktop client for Windows, Linux, and macOS that uses direct InnerTube API communication and aggressive caching to provide instant navigation and playback.

Web DevelopmentFrontend Frameworks
226
TanStack
Featured
TanStack GitHub avatar

router

TanStack Router is a type-safe, data-driven React router with built-in caching, prefetching, and nested layouts, while TanStack Start extends it into a full-stack SSR framework.

Web DevelopmentFrontend Frameworks
14,861
react
Featured
react GitHub avatar

react

React is a JavaScript library for building user interfaces with declarative, component-based, and cross-platform design.

Web DevelopmentFrontend Frameworks
246,741