-
I have a funky case of a I right now have a When the latter has a state-change I don't want to re-render the former. That's why they're separated out explicitly. Here's how I do things now, note the unwanted const trs: ChildDom[] = _.fields.map(fieldTr) // fieldTr not included here, does tags.tr(tags.td(...), tags.td(...))
if (_.dynFields)
trs.push(() => tags.span(..._.dynFields.val.map(fieldTr))) // dont want to have to do the span here!!
const table = tags.table({}, ...trs) Whether I use span or div or data or whatever, it renders faulty (and strictly speaking, HTML-wise it is faulty — This function which must satisfy the (I mean worst-case I could ditch the |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Well I already switched from the table/tr/td design to divs and it's fine. There might be other cases for the BindingFunc idea I asked about, but right now I'm not suffering any — so feel free to close thread at your discretion =) |
Beta Was this translation helpful? Give feedback.
-
Hi @metaleap, Thanks for reaching out! I think for your case, |
Beta Was this translation helpful? Give feedback.
Hi @metaleap,
Thanks for reaching out!
I think for your case,
<tbody>
can be a good container elements for a group of multiple<tr>
elements. Note that it's allowed to have multiple<tbody>
elements within a<table>
element, see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tbody#usage_notes.