๐Ÿš€ Gen 5 of the leading AI app deployment platform launches October 6. Click for the livestream.

Custom paging with dash is very unclear. What can I do to improve it?

I am making a Dash app that has a very large datatable so there are always multiple pages. Since I have custom sorting, I must use custom paging. The paging works fine but it is very unclear since it only tells you what the current page is and allows you to go to prev/next.

I have read through the documentation here Python-Driven Filtering, Paging, Sorting | Dash for Python Documentation | Plotly and in the example for custom paging it looks like they provided a value for page count (but this isnโ€™t the actual number of pages in the table).

Is there a way to get the total number of pages returned by the table? One method I thought of would be to get the number of results returned and then divide by the page_size to get the number of pages returned. Once I have this value though, how can I display it nicely like the native paging does?
Additionally, is there a way to bring you back up to the top of the page when the next page button is clicked?

Thank you in advance :grinning_face_with_smiling_eyes: :kissing_heart: