amis-rpc-design/node_modules/rc-tree-select/lib/hooks/useTreeData.d.ts
2023-10-07 19:42:30 +08:00

9 lines
435 B
TypeScript

import * as React from 'react';
import type { DataNode, SimpleModeConfig } from '../interface';
import type { DefaultOptionType } from '../TreeSelect';
/**
* Convert `treeData` or `children` into formatted `treeData`.
* Will not re-calculate if `treeData` or `children` not change.
*/
export default function useTreeData(treeData: DataNode[], children: React.ReactNode, simpleMode: boolean | SimpleModeConfig): DefaultOptionType[];