I would like to display a list of elements using virtual-virtualized, however some elements may resize.
I added a demo where each element has a button, and when someone clicks the button, then the element needs to be expanded and click the lower positions below:
https://plnkr.co/edit/GG2bSIC5M1Gj7BR1pOii
The use case is similar to the posts in facebook, when someone notices that he will expand the message, and other messages will be lower.
ReactDOM.render(
<List
className='List'
autoHeight
width={300}
height={400}
rowCount={list.length}
rowHeight={30}
rowRenderer={
({ index, isScrolling, key, style }) => (
<div
className='Row'
key={key}
style={style}
>
{list[index]}
<Expander /> /* contains the button, which when click it will expand more text*/
</div>
)
}
/>,
document.getElementById('example')
Is there any way to achieve this?
UPDATE
, List . InfiniteLoader (- ), registerChild . , InfiniteLoader , .
forceUpdate , List - .
https://plnkr.co/edit/RftoShEkQW5MR5Rl28Vu