New Features
- Adapters
- New
registerAdapter()API to extendanimate()andutils.set()to non-DOM targets (learn more: https://animejs.com/documentation/adapters)
- New
- Three.js adapter
- New built-in three.js adapter, imported as a side-effect from
animejs/adapters/three, to animateObject3D, materials, lights, cameras, audio nodes,UniformNode(TSL) and instanced meshes (learn more: https://animejs.com/documentation/adapters/three)
- New built-in three.js adapter, imported as a side-effect from
- Stagger
- Auto-grid mode now supports 3D layouts, using
{x, y, z}coordinates or an explicitgrid: [columns, rows, depth]triplet - The
fromparameter now accepts[x, y, z]normalized coordinates andaxisnow accepts'z'for 3D grid origins - New
jitterparameter to add a random offset to staggered values, either a single number or a[start, end]range - New
seedparameter to makejitterandfrom: 'random'reproducible
- Auto-grid mode now supports 3D layouts, using
Bug Fixes and improvements
- Color
- Color animations now blend RGB channels in pseudo-linear space for smoother, more even transitions (intermediate colors differ slightly from previous versions)
- Render
- Fix a flicker that could appear randomly between iterations of reversed loops
- Fix a flicker that could appear randomly on alternate loops when using non-integer duration values
- Timeline
- Fix a backward seek leaving a timeline child stuck at its end value when all its properties share the same delay
- Fix a timeline child whose delay is longer than its duration overwriting a later sibling's value on a forward seek
- Fix stale values when seeking a timeline whose children animate the same property through delayed tweens, most visible with staggered
jitterdelays - Fix an implicit
fromvalue resolving to a stale value when an overridden tween sits earlier in the chain - Improve performance when building large timelines with many overlapping
.add()calls on the same property, and fix a case where such a timeline could cancel itself
- Keyframes
- Fix a floating point precision issue producing incorrect intermediate values in keyframe arrays
- Fix scrubbing backward past the start of a keyframe sequence not restoring the first keyframe's
fromvalue - Fix scrubbing forward past the end of a keyframe sequence leaving the target stuck on a previous keyframe's value
- Fix sequential keyframes occasionally detected as overlapping because of floating point drift, leaving the target stuck on the wrong value when scrubbing
- Animation
- Fix function-based and CSS variable
fromvalues in object form ({ from, to }) not re-resolving onrefresh() - Fix
stretch()not correctly scaling animations that use keyframes
- Fix function-based and CSS variable
- Scroll
- Fix a
getBoundingClientRectcrash that could happen when a scroll container resized before its target was ready
- Fix a
- Engine
- More accurate frame scheduling that no longer drops frames arriving slightly early because of
requestAnimationFramejitter - Faster
engine.speedandengine.timeUnitupdates that skip unnecessary work when the value does not actually change
- More accurate frame scheduling that no longer drops frames arriving slightly early because of