Documentation

Motion Solid

A Solid-native port of Motion that keeps the Motion React API while adding fine-grained primitives — createMotionValue, createTransform, createSpring, and friends. Every public API has its own page below with a live example.

Guides

6 APIs

Components

8 APIs

Primitives

24 APIs
useMotionApply motion props to any element without using a motion.* wrapper.createAnimateImperative animation scoped to a ref, usually called from a handler or effect.createAnimateMiniMinimal sibling of createAnimate. It keeps only the WAAPI subset for smaller bundles.createAnimationFrameSubscribe a callback to motion's shared animation-frame loop.createCombinedMotionValueLow-level: derive a MotionValue from a computation and explicitly subscribe its sources.createComputedRead multiple motion values inside a getter and expose the result as a new motion value.createCycleA small state primitive that cycles through a fixed list of values.createDragControlsStart a drag programmatically when the handle is separate from the draggable element.createFollowValueA motion value that follows another with configurable latency.createInViewTrack whether an element is inside the viewport or a custom root.createInstantLayoutTransitionWrap a synchronous update so layout snapshots are measured without playing a visible transition.createLayoutGroupPrimitives behind <LayoutGroup>: read the surrounding group or provide one manually.createMotionTemplateA tagged template that interpolates motion values into a single derived string value.createMotionValueA reactive value type that can update outside Solid's signal graph.createMotionValueEventSubscribe to lifecycle events on a motion value: change, animationStart, animationComplete, or animationCancel.createMotionValueSignalMirror a MotionValue into a Solid signal for use in tracked scopes.createReducedMotionA boolean accessor that reflects the user's prefers-reduced-motion setting.createReducedMotionConfigRead the effective reduced-motion preference, factoring in MotionConfig's override.createScrollTrack the scroll progress of the page, a container, or a target element.createSpringSmooth a motion value or static value with a spring.createTimeA motion value that ticks with the document timeline.createTransformDerive a new motion value by mapping another through a function or an input/output range.createVelocityA motion value tracking the instantaneous velocity of another.usePresenceRead and coordinate presence state inside an AnimatePresence child.

Functions

9 APIs

47 APIs documented · Looking for a runnable demo? Browse examples →