Git Product home page Git Product logo

Comments (6)

bvaughn avatar bvaughn commented on May 5, 2024

1 The component height but instead calculate based on the just the heights of the element itself.

I'm thinking of creating a wrapper component that will automatically expand a list or table to fill the available width and height. I'm thinking of something kind of like this:

<AutoSizer
  ChildComponent={VirtualScroll}
  rowsCount={list.size}
  rowHeight={20}
  rowRenderer={() => {
    // Your renderer here
  }}
/>

2 The rowHeight and instead base that on the content of the height

Supporting dynamic row height is pretty complicated. I actually created issue #23 to experiment with this.

from react-virtualized.

bvaughn avatar bvaughn commented on May 5, 2024

Okay so I created an AutoSizer component as described above. I'd be interested in hearing your thoughts once you've had a chance to play with it. I'll try to release it in an update sometime this afternoon.

from react-virtualized.

bvaughn avatar bvaughn commented on May 5, 2024

This component is available in release 2.5.0. Check it out.

from react-virtualized.

oyeanuj avatar oyeanuj commented on May 5, 2024

@bvaughn Happy New Year and Sorry for disappearing but just getting a chance to get back to the project and this use-case. I am excited to try it out!

(Btw, the link to docs on Autosizer lead to an empty page. Not sure if that was the wrong link or you just haven't had a chance to add them. Either way, thought I should mention it.)

Thanks again for your work and receptiveness to issues! :)

Edited to withdraw a question I asked. I just didn't read the description of the component carefully :/

from react-virtualized.

bvaughn avatar bvaughn commented on May 5, 2024

Happy new year to you also, @oyeanuj!

Thanks for pointing out the bad docs link. Looks like I forgot to actually write those docs. (Whoops.) I will fix it momentarily. :)

from react-virtualized.

Hari-Shankar-3296 avatar Hari-Shankar-3296 commented on May 5, 2024

Thanks for this wonderful library, @bvaughn. Which I have used in some places in different apps. But still, I am quite confused about some concepts. Is there any demo for chat messages virtualization which will have auto height rows and auto height List? i.e there is no fixed height for the list as well as rows.

from react-virtualized.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.