Animatable

Represents an animatable property that can have keyframes or a static value.

Animatable interface

Represents an animatable property that can have keyframes or a static value.

Signature:

interface Animatable<T>

Remarks

When isAnimated is false, the property uses staticValue. Setting staticValue when keyframes exist will not affect the animation

Example

// Set static value
layer.position.staticValue = { x: 100, y: 200 };

// Add keyframes for animation
layer.position.addKeyframes([
  { frame: 0, value: { x: 0, y: 0 } },
  { frame: 30, value: { x: 100, y: 200 } },
]);

Properties

Property

Modifiers

Type

Description

isAnimated

readonly

boolean

Whether this property has any keyframes

keyframes

readonly

ReadonlyArray<Keyframe<T>>

Array of all keyframes for this property

staticValue

T

The static value used when the property is not animated

Methods

Method

Description

addKeyframes(keyframes)

Adds one or more keyframes to this property.

clearKeyframes()

Removes all keyframes from this property.

getKeyframeAt(frame)

Gets the keyframe at a specific frame number, if one exists.

getValueAt(frame)

Gets the interpolated value of this property at a specific frame, or the current playhead if omitted.

Last updated: August 5, 2026 at 11:47 AMEdit this page