design-infraGitHub
Report a problem or share feedback← Catalog

Value transform & path drawing

free

motion/use-transform

An example of linking SVG path length to a drag gesture using Motion for React's easy useTransform hook.

drag — mediumrecipeOrganicTrustworthyRefined
$pnpm add motion # then adapt the free source from https://motion.dev/examples/react-use-transform

npm deps: motion

Value transform & path drawing preview
Source
Motion (motion.dev)
Kind
transition
Categories
transition, form
Use as
recipe — technique you apply to your own markup
Applies to
form
Motion
on drag · medium · motion · medium cost
Tags
motion, useMotionValue, useTransform, drag
Licence
motion / motion/react / motion-v are MIT. Motion+ (premium components, example source, AI Kit pro tools) is paid — one-time Personal licence or per-seat Business.
Live demo
motion.dev
Docs
motion.dev