I don't know if this is the right way to use custom elements, but if you squint at this, it's a way to put one tag around a table and have it sortable and filterable.
-
I don't know if this is the right way to use custom elements, but if you squint at this, it's a way to put one tag around a table and have it sortable and filterable.
When doing front-end, it's this logic that is always tricky and feels like a solved problem. How much JS is out there that sorts a <table> by column? And so to me, custom elements seems like a way to make one solution that DOESN'T bring in visuals/styling along with it.
https://ruby.social/@davetron5000/113211897309699011 -
Jason Garberreplied to Dave Copeland :ruby: last edited by
@davetron5000 …not quite the same thing, but it reminds me of @zachleat’s table-saw:
table-saw Web Component—zachleat.com
A post by Zach Leatherman (zachleat)
Zach Leatherman (www.zachleat.com)
-
Zach Leatherman :11ty:replied to Jason Garber last edited by
@jgarber @davetron5000 @raymondcamden has done some great work here too! https://www.raymondcamden.com/2023/03/14/progressively-enhancing-a-table-with-a-web-component