Skip to content

ProgressReadablePort

export interface ProgressReadablePort extends SnapshotPort {
readonly progress: number; // 0..1
}

A port providing a progress value between 0 and 1. Used to pass state that can be expressed as a ratio, such as scroll amount or animation progress.

PropertyDescription
progressProgress value from 0.0 to 1.0

Must inherit from SnapshotPort. When snapshot() is called, the port must capture the value at that moment and maintain it internally, ensuring that progress does not change until the next snapshot().