react-mini-treeview
v1.2.1
Published
A lightweight tree view component for React.
Downloads
22
Readme
react-tree-view
A lightweight tree view component for React.
demo
https://react-tree-view.vercel.app
demo source
https://github.com/PaigeWw/react-tree-view/tree/main/example
preview
Usage
import TreeView from ''
<TreeView
dataSource={dataList as DataSource[]}
height={800}
width={1200}
LeafNodeComponent={LeafNodeComponent}
leafHeight={80}
leafWidth={360}
ref={treeViewRef}
/>
API
type TreeViewProps = {
dataSource: DataSource[];
width?: number;
height?: number;
ref?: React.MutableRefObject<any>;
leafHeight: number;
leafWidth: number;
LeafNodeComponent: React.FC<any>;
}