Comments (6)
Hi @aquach,
Correct me if I'm wrong, but you should be able to use the onRowsRendered
callback (supported by FlexTable
and VirtualScroll
) for this purpose. I suspect what you care about is the range of rows rendered (or the fact that they've changed) and not the actual scroll position.
This callback's signature is expected to be: ({ startIndex, stopIndex }): void
Going to close this issue as answered (because I think it is) but please comment again if you have more questions or if this isn't an adequate answer. :)
from react-virtualized.
I actually need it to support our existing in-house infinite loading code, which checks to see if one's scrolled close to the bottom of available content. I suppose onRowsRendered is a more quantized way to do that. If implemented via onRowsRendered, it may interact poorly with #53. If many extra elements are rendered, the client may not be able to use onRowsRendered to reliably detect scrolling close to the end of the content.
from react-virtualized.
Have you considered using the InfiniteLoader
component for this? (Sorry if we've already talked about this.)
The implementation for #53 will allow you to configure the number of overflow rows rendered, so you would have to take that into account within your own onRowsRendered
callback.
from react-virtualized.
Our infinite loading is date-based rather than index-based and comes with a bit of extra domain logic, so integrating the infinite loader would take some extra effort. We opted to stick with what we already had. Thanks for asking though!
from react-virtualized.
I see. Always interesting to hear about different project's requirements. :)
I do strongly prefer the use of the onRowsRendered
callback for this purpose though. I'd rather avoid adding another callback for scrolling because I think it may muddy the interface and confuse people. (Ideally no one should care about the inner dimensions/offsets of virtualized components, only which rows are visible at any given time).
Let's chat again once I've got an implementation for #53 up though and we'll see if we can't work something out. :)
from react-virtualized.
Sure thing, thanks for being so responsive!
On Wed, Jan 13, 2016 at 4:10 PM Brian Vaughn [email protected]
wrote:
I see. Always interesting to hear about different project's requirements.
:)I do strongly prefer the use of the onRowsRendered callback for this
purpose though. I'd rather avoid adding another callback for scrolling
because I think it may muddy the interface and confuse people. (Ideally no
one should care about the inner dimensions/offsets of virtualized
components, only which rows are visible at any given time).Let's chat again once I've got an implementation for #53
#53 up though and
we'll see if we can't work something out. :)—
Reply to this email directly or view it on GitHub
#60 (comment)
.
from react-virtualized.
Related Issues (20)
- The web link is wrong. HOT 2
- Confused about zooming with virtualization HOT 1
- Accessibility issues in Table, Column components HOT 2
- Is this Project Dead or Unmaintained? Which are the alternatives? HOT 2
- How using checkbox in react-virtualized?
- Grid rows disappear when sibling elements are conditionally rendered in HOT 1
- [Question] What are the criteria for determining the number of rows in a list?
- Your official website is blocked HOT 1
- Main link is broken HOT 1
- Access to Multigrid public method recomputeGridSize() returns undefined
- Version 9.22.5 is a ghost not visible in this repository?
- Height Issue after rendering
- Virtualisation fail ? Why invisible content is added to my list ?
- react18.2.0 HOT 1
- Tips for displaying a dropdown to overflow the React Virtualized container without being hidden?
- Failed to fetch dynamically
- The styles.css isn't part of the 9.23.0 version
- How to load JSON-formatted data virtually?
- TypeError : RegisterChild in WindowScroller
- Props ScrollElement of WindowScroller load every items if parent is InfiniteLoader HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-virtualized.