Node
<Node />
#
#
Use ๐งA React Component to render a particular node, and optionally, all of its children.
#
Props โ๏ธid: String
The ID of the node to collect.
view: Object
An object representing what will be rendered to the screen for the node with the given id. Its keys should be the 'type' Strings used when nodes are created, and its values should be React Components.
You should pass this view component for all types since Node initially only knows the id from the passed prop and does not know the type. The type and what to render is inferred by collecting the node's data through its id.
note
If no view is provided, the Node Component will not render anything.
shallow: Boolean
Flag to indicate whether or not to render the node's children as well. If it is true, Node will only render node with id.
info
Default value for this prop is false.
#
Example Usage ** ๐- ** See more about useCollector.