ant design pro table 表格树形数据 children 为空数组时的显示问题


如果展开的数据是点击后异步加载的,即使 children 为 [] 也需要出现 [+] 按钮,否则就无法操作了。保持原来的逻辑才能满足这个需求:

  1. children 为 [] 时有 [+]
  2. children 不存在或是 nullfalse 时,不展示 [+]