HistoryManager

See source code
Table of contents
class HistoryManager<R extends UnknownRecord> {}

Constructor

Constructs a new instance of the HistoryManager class

Parameters

NameDescription

opts

{
  annotateError?(error: unknown): void;
  store: Store<R>;
};

Properties

dispose

readonly
readonly dispose: () => void;

Methods


bail( )

bail(): this;

bailToMark( )

bailToMark(id: string): this;

Parameters

NameDescription

id

string;

Returns

this;

batch( )

batch(fn: () => void, opts?: TLHistoryBatchOptions): this;

Parameters

NameDescription

fn

() => void;

opts

Returns

this;

clear( )

clear(): void;

getNumRedos( )

getNumRedos(): number;

getNumUndos( )

getNumUndos(): number;

redo( )

redo(): this;

squashToMark( )

squashToMark(id: string): this;

Parameters

NameDescription

id

string;

Returns

this;

undo( )

undo(): this;

Prev
HandleSnaps
Next
InputsManager