最关键的两个参数就是onExpandedRowsChange和expandedRowKeys
参考博客https://blog.csdn.net/wangxu000000/article/details/115304817
代码仅供参考
const [expandedRowKeys, setExpandedRowKeys] = useState([''])
//展开当前行 关闭另一行
const expandRows = (rows
最关键的两个参数就是onExpandedRowsChange和expandedRowKeys
参考博客https://blog.csdn.net/wangxu000000/article/details/115304817
代码仅供参考
const [expandedRowKeys, setExpandedRowKeys] = useState([''])
//展开当前行 关闭另一行
const expandRows = (rows