TanStack

cloneState

Function: cloneState()

ts
function cloneState<T>(value): T;

Defined in: utils.ts:22

Clones table state values while preserving non-plain objects.

Plain objects and arrays are copied recursively so state updates can avoid mutating existing references.

Type Parameters

T

T

Parameters

value

T

Returns

T