zhihanyue / qgridnext

Advancing QGrid, an interactive grid for exploring DataFrames in JupyterLab/Notebook
https://qgridnext.readthedocs.io
Apache License 2.0
19 stars 1 forks source link

Pagination support? #5

Closed jnaylor92 closed 5 months ago

jnaylor92 commented 5 months ago

How feasible is it to get pagination support?

zhihanyue commented 5 months ago

Qgrid implements lazy loading upon scrolling, which offers an efficiency comparable to that of pagination. For those scenarios where you need to view a fixed range of data, a workaround is to utilize the filtering capabilities on the id column or any other relevant criteria to narrow down the data as required. At this moment, there are no plans to implement pagination.

jnaylor92 commented 5 months ago

Is the number of elements loaded by the lazy loading configurable? Thanks for the ID narrowing suggestion, might look into it

zhihanyue commented 5 months ago

Is the number of elements loaded by the lazy loading configurable? Thanks for the ID narrowing suggestion, might look into it

No, the page size is hardcoded to 100. Specifically, when we scroll to the page boundary, It loads data from i-100 to i+100 for position i.