RollingCounterSnapshot

import { RollingCounterSnapshot } from "jsr:@ende/data-structures/unstable-rolling-counter";

interface ยท experimental

interface RollingCounterSnapshot

A serializable snapshot of a RollingCounter's state.

Obtain one via toJSON and restore it with RollingCounter.from.

Properties

segments

readonly segments: readonly number[]

Segment counts ordered from oldest to newest.

Source