https://ant.design/components/table#expandable
This sample is not working, it displays expandIconColumnIndex=0 and creates an empty column in the desired position:
const columns = [
// here display expand column
{
title: 'ID',
dataIndex: 'id',
key: 'id',
},
{
title: 'Created_at',
dataIndex: 'created_at',
key: 'created_at',
},
{
title: 'Publication',
children: [
{
title: 'Title',
dataIndex: 'title',
key: 'title',
},
{
title: 'Author',
dataIndex: 'author',
key: 'author',
},
Table.EXPAND_COLUMN, // here display empty column
],
},
{
title: 'Note',
dataIndex: 'note',
key: 'note',
},
]
Displays expand column in children column "Publication"
Columns -> 'Publication' -> EXPAND_COLUMN
Displays 2 column, first column of index 0 default expand column, second column of index 4 empty
Environment | Info |
---|---|
antd | 5.16.4 |
React | React 18.2.0 |
System | Windows 11 |
Browser | Google Chrome |
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too