Skip to content

Consider creating VTable component for better table support #312

Closed

Description

@inokawa

Activity

  1. mariia-mitiureva commented on Jan 8, 2024

    @mariia-mitiureva
    Contributor

    Hi @inokawa
    Should this ticket solve the problem that body cell width doesn't match header cell width (when we don't set fixed cell width like in original storybook example) ?
    image

    Looks like it doesn't work properly because of position: absolute. I checked this example with mui table + react-virtuoso https://mui.com/material-ui/react-table/#virtualized-table . They don't set height to tbody directly, but add additional rows to the beginning and to the end to control scroll height and visible rows position, and avoid position: absolute.

  2. inokawa commented on Jan 8, 2024

    @inokawa
    OwnerAuthor

    Hi, the purpose of this issue is to find a stable way to virtualize table element with virtua, because table virtualization is very tricky...
    I'll take a look mui table example. Thank you!

  3. self-assigned this
    on Jan 10, 2024
  4. removed their assignment
    on Oct 12, 2024
  5. junwen-k commented on Feb 16, 2025

    @junwen-k

    In addition to that, @tanstack/react-virtual follows a similar approach to MUI virtualization, but without relying on absolute positioning. I agree with @mariia-mitiureva regarding the current limitations of Virtua.

    I hope this feature gets prioritized soon, but I understand that open-source work takes time and effort. Looking forward to seeing where this goes!

  6. changed the title [-]Better table support[/-] [+]Consider creating VTable component for better table support[/+] on Oct 18, 2025
  7. tresorama commented on Oct 20, 2025

    @tresorama

    Just an Idea for an API with VList

    <table>
      <thead>
        <tr> 
        </tr>
      </thead>
      <VList 
    +  rootElement={'tbody'}
    +  // or
    +  rootElement={TbodyComponent} 
      >
          <tr>
            <td> Cell 1</td>
            <td> Cell 2</td>
          </tr>
    </VList>
    
  8. inokawa commented on Dec 4, 2025

    @inokawa
    OwnerAuthor
  9. inokawa commented on Dec 4, 2025

    @inokawa
    OwnerAuthor

    For anyone visited here, is it necessary to render with table tag? And what features do you need from VTable?

    The most difficult part of virtualized table is table tag has strict markup/style restriction. Virtualized table-like grid with div is easier with virtua's architecture, and we could support more features like sticky column/row (#635) or rowspan/colspan (#312 (comment)).

  10. mary-ext commented on Dec 4, 2025

    @mary-ext

    it might be fine so long as screen readers can read them properly (this is mostly up to the consumers of the library, but so long as the library ensures it's possible to do so, then it's good)

  11. g3tl0st commented on Dec 4, 2025

    @g3tl0st

    I recently built a complex data-table using tanstack table and virtua. for me, i think table tag made me much easier to built that complex thantable-like grid with div.

    i'll create a minimal example (demo) for u, when i got time"

  12. self-assigned this
    on Sep 14, 2026
  13. inokawa commented on Sep 19, 2026

    @inokawa
    OwnerAuthor

    Shipped VGrid component in 0.52.0, which has role="table". Any feedback is welcome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions