Open domenic opened 6 years ago
Even if controversial, using is=""
would really help here, as we could do something like this
class VirtualTableElement extends VirtualScrollerMixin(HTMLTableElement) {
// ...
}
customElements.define('virtual-table', VirtualTableElement, { extends: 'table' });
and use it like this
<table is="virtual-table">
<template> <tr><td>cell!</td></tr> </template>
</table>
(note: VirtualScrollerMixin would be where most of the current implementation relies)
Virtual tables are really important in enterprise grade SaaS (which are important for GCP :) ). All CRMs, ERPs, "you-name-it" use a huge amount of tables/data grids and virtual scrolling is critical there, because old school pagination is no more suitable and pretty impossible to work with.
Long time ago in some demo project we was testing ExtJS buffered grid. Was working pretty fine. Probably worth to look into because it is one of most "enterprise'e" framework and probably are accumulating huge amount of expertise.
I am not an expert in programming. More like a PO. But yesterday had an idea to try this
A common use case on the web is data tables, using the
<table>
element... but virtualized.Can this be done using our implementation?
(Note: column auto-sizing seems basically impossible. All columns would have to be fixed width.)
I can see a few paths here:
table > virtual-scroller > tr
. This can only be done with DOM APIs; the parser will transform that intovirtual-scroller + table > tr
. If this can be made to work, we could consider making it easier to use somehow.This seems like an area ripe for exploration and hacking around.