Horizontal scroll in React Table
21,400
Just simply add style with a height of 400px, that will force it to be scroll able.
<ReactTable
data={bookingPerson}
columns={columns}
className="-striped -highlight"
defaultPageSize={7}
loading={loading}
style={{
height: "400px"
}}
/>
Author by
Murakami
Updated on June 25, 2020Comments
-
Murakami about 4 years
I have a problem to get pretty basic functionality, ie. I'd like to set horizontal scroll on React table when the page is less wider then the table size. There is nothing unusual in my code but I'll leave it here anyway:
<ReactTable data={bookingPerson} columns={columns} className="-striped -highlight" defaultPageSize={7} loading={loading} />