Variable: rootRef
const rootRef: <T>(modelTypeId, options?) => RefConstructor<T>;
Creates a root ref to an object, which in its snapshot form has an id. A root ref will only be able to resolve references as long as both the Ref and the referenced object share a common root.
Type Parameters
| Type Parameter | Description |
|---|---|
T extends object | Target object type. |
Parameters
| Parameter | Type | Description |
|---|---|---|
modelTypeId | string | Unique model type id. |
options? | RootRefOptions<T> | Root reference options. |
Returns
A function that allows you to construct that type of root reference.