UNPKG

mobx-keystone-mindreframer

Version:

A MobX powered state management solution based on data trees with first class support for Typescript, snapshots, patches and much more

15 lines (14 loc) 512 B
/** * Checks if a given object is now a tree node. * * @param value Value to check. * @returns true if it is a tree node, false otherwise. */ export declare function isTreeNode(value: unknown): value is object; /** * Asserts a given object is now a tree node, or throws otherwise. * * @param value Value to check. * @param argName Argument name, part of the thrown error description. */ export declare function assertIsTreeNode(value: unknown, argName?: string): asserts value is object;