Reputation: 23
const columns = [{
dataField: 'firstName',
text: 'Visitor Name'
},
{
dataField: 'lastName',
text: ''
},];
<BootstrapTable keyField='id' data={ products} columns={ columns } />
Here firstName and lastName should be in one column.
Upvotes: 2
Views: 2499
Reputation: 89
If you want to show multiple data fields in a single Column, you can use formatter prop Formatter function. It gives you cell and row with which you can easily add multiple datafields in single columns. Here is the working example for you - Example
Upvotes: 4