Pagination dropdown getting close when setState({ data })
See original GitHub issueI’m using react-bootstrap-table with remote data and fetching the data every few seconds to update the table.
<BootstrapTable
remote={ true }
data={ this.state.data }
....
And when fetching the data I use setState({ data })
.
If I open the pagination menu - once the component is refreshed with the data from the server - the dropdown is getting closed automatically.
I’m using version 3.0.0
Is there something I can do to keep the pagination dropdown open?
Issue Analytics
- State:
- Created 7 years ago
- Comments:9 (9 by maintainers)
Top Results From Across the Web
Unable to clear cache and make another API call based on ...
So whenever I change contentTypeDropdown value the cache should be cleared ... import { AsyncPaginate } from 'react-select-async-paginate';.
Read more >React setState async cause the delay of dropdown
I was trying to made a dropdown with default value. So, for example, it shows "Year" at the beginning, after clicking user should...
Read more >How To Build Custom Pagination with React | DigitalOcean
Start a new React application using the create-react-app command. You can name the application whatever you'd like, but this tutorial will name ...
Read more >Improve the performance of dropdown containing large data ...
In this blog, we will share how the problem was solved using 'Virtualization'. Let's first go through the term 'Virtualization'.
Read more >How to Implement Infinite Scrolling with React.js | Pluralsight
Here in this guide, we will develop a simple custom infinite scrolling mechanism that helps us to load data based on a scroll...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
sorry for lately reply cause of my busy job…
yap, it’s not a bug, because a re-render happen via setState
there’s no any good way to achieve easily, but you can custom the dropdown and keep it always open, check this and add a props
hidden={ false }
onSizePerPageDropDown
Ley me know if you have any questions, thanks
Try
v3.1.8
, you can get the dropdown DOM via.react-bs-table-sizePerPage-dropdown
and register it with DropDown Events