@typescript-package/history
Version:
A lightweight TypeScript package for tracking the history of values.
27 lines (26 loc) • 883 B
TypeScript
import { Data, DataCore } from '@typescript-package/data';
import { HistoryBase } from './base/history-base.abstract';
/**
* @description The class to manage the value changes.
* @export
* @class History
* @template Value
* @template {number} [Size=number]
* @template {DataCore<Value[]>} [DataType=Data<Value[]>]
*/
export declare class History<Value, Size extends number = number, DataType extends DataCore<Value[]> = Data<Value[]>> extends HistoryBase<Value, Size, DataType> {
/**
* @description The max size for undo history.
* @public
* @static
* @type {number}
*/
static size: number;
/**
* @description Returns the `string` tag representation of the `History` class when used in `Object.prototype.toString.call(instance)`.
* @public
* @readonly
* @type {string}
*/
get [Symbol.toStringTag](): string;
}