1

Is it possible to format multi-tiered headers with LWC lightning-datatable component? I do not see anything in documentation, and I've tried passing in nested array of headers into columns attribute. But no luck.

An example is linked on W3 Org website. And I've attached a screenshot for clarity.

Any suggestions or workarounds?

enter image description here

0
2

Unfortunately, this is not supported. The lightning-datatable is designed after SLDS, which does not have an allowance for multiple header rows or cells that span more than one column. You'd have to roll your own table instead.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.