Cannot read property 'isKey' of undefined in BootStrapTable
In my case it was because of
`<TableHeaderColumn dataField='AgentName' >Name</TableHeaderColumn></BootstrapTable>` in which BootstrapTable's Closing tag was on a same line .
it should be there on a new independent line.
See Below Example:
#Wrong Implementation:
<BootstrapTable
data={products}
options={options}
pagination={true}
exportCSV>
<TableHeaderColumn dataField='TxId' isKey={true}>TxId </TableHeaderColumn>
<TableHeaderColumn dataField='AgentName' >Name</TableHeaderColumn></BootstrapTable>
#Correct Implementation:
<BootstrapTable
data={products}
options={options}
pagination={true}
exportCSV>
<TableHeaderColumn dataField='TxId' isKey={true}>TxId </TableHeaderColumn>
<TableHeaderColumn dataField='AgentName' >Name</TableHeaderColumn>
</BootstrapTable>
`<TableHeaderColumn dataField='AgentName' >Name</TableHeaderColumn></BootstrapTable>` in which BootstrapTable's Closing tag was on a same line .
it should be there on a new independent line.
See Below Example:
#Wrong Implementation:
<BootstrapTable
data={products}
options={options}
pagination={true}
exportCSV>
<TableHeaderColumn dataField='TxId' isKey={true}>TxId </TableHeaderColumn>
<TableHeaderColumn dataField='AgentName' >Name</TableHeaderColumn></BootstrapTable>
#Correct Implementation:
<BootstrapTable
data={products}
options={options}
pagination={true}
exportCSV>
<TableHeaderColumn dataField='TxId' isKey={true}>TxId </TableHeaderColumn>
<TableHeaderColumn dataField='AgentName' >Name</TableHeaderColumn>
</BootstrapTable>
Comments
Post a Comment