Antd Hooks

1、useSate

  Demo:

      const [createModalVisible, handleModalVisible] = useState<boolean>(false);

      初始化组件state,类型为布尔类型,初始化参数为false

 

2、useModel

 

3、useRef
   const actionRef = useRef<ActionType>();

posted on 2020-07-30 17:50  滚动的蛋  阅读(622)  评论(0编辑  收藏  举报

导航