Comments (10)
+1
from react-virtualized.
For anyone following along on this issue, PR #37 is coming along nicely. Would have been finished already if not for the holidays but I hope to have it wrapped up by the end of the weekend.
from react-virtualized.
Resolved via PR #37
from react-virtualized.
@bvaughn Just so I understand it clearly, the idea here is that instead of a fixed height, one passes a function that determines the height for that row? And every time, the height of a child row changes, it should update its 'smart' parent container which hosts this rowHeightDeterminant function?
from react-virtualized.
Right. The rowHeight
property can now be a number (for fixed heights) or a function that returns a height for a given row-index (for dynamic heights).
If a child row's height changes you may need to call recomputeRowHeights
as mentioned in the docs (depending on whether that change is accompanied by other props changes).
You can see some example source code I wrote (used to create the demo page) here:
https://github.com/bvaughn/react-virtualized/blob/master/source/VirtualScroll/VirtualScroll.example.js
from react-virtualized.
@bvaughn Is recomputing row heights a deprecated feature? Given the situation:
<Parent>
<List
{...props}
rowHeight={this.getRowHeight}
{...parent.state}
/>
</Parent>
is it possible for a change to the parent's state not only re-render the children in the render method—per as mentioned in the section of pure components—but also trigger a recalculation of the rowHeights?
from react-virtualized.
Probably.
There isn't really enough info here for me to answer.
What have you tried? Where's the code? What version of RV are you using? (If it's really old, as your wording suggests, then that's probably an important detail).
Stack Overflow is probably better for this sort of question :)
from react-virtualized.
Just figured I’d ask here given there used to be a recomputeRowHeights
method. Now it’s not documented anywhere, nor does there seem to be a documented alternative. Using the latest LTS version.
EDIT: Read latest major version (v9.x.x) rather than Long Term Support version.
from react-virtualized.
Just figured I’d ask here given there used to be a
recomputeRowHeights
method. Now it’s not documented anywhere, nor does there seem to be a documented alternative.
What documentation are you looking at? recomputeRowHeights
is documented here.
Using the latest LTS version.
"LTS" ? I'm not sure what this means.
Anyway, GitHub issues are meant for bug reports and feature-requests. It's hard to scale questions, especially if there's not much information (as is the case here).
from react-virtualized.
Didn’t see those docs, thank you 🙏
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.