react-organizational-chart
Simple react hierarchy tree - any React children accepted for nodes
Install
Usage
Examples
Styled tree
Components
Tree
- The root of the tree
Accepts the following props:
- label: (required) Any react
Node
- children: (required) Any number of
<TreeNode>
- lineHeight: (default 20px) The height of the Path as a css length
- lineWidth: (default 1px) The width of the Path as a css length
- lineColor: (default black) The color of the Path as a css color
- lineBorderRadius: (default 5px) The color of the Path as a css border-radius
- nodePadding: (default 5px) The left and right padding of every
<TreeNode>
as a css length
TreeNode
- A node in the tree
- label: (required) Any react
Node
- children: (required) Any number of
<TreeNode>