mobx-keystone
Version:
A MobX powered state management solution based on data trees with first class support for TypeScript, snapshots, patches and much more
17 lines (16 loc) • 499 B
TypeScript
/**
* Returns if the target is a "child" of the tree of the given "parent" object.
*
* @param child Target object.
* @param parent Parent object.
* @returns
*/
export declare function isChildOfParent(child: object, parent: object): boolean;
/**
* Returns if the target is a "parent" that has in its tree the given "child" object.
*
* @param parent Target object.
* @param child Child object.
* @returns
*/
export declare function isParentOfChild(parent: object, child: object): boolean;