techniq / mui-table

Improved Material-UI table
https://techniq.github.io/mui-table/
MIT License
45 stars 12 forks source link

Support column spanning and multiple header rows #11

Closed techniq closed 6 years ago

techniq commented 6 years ago
techniq commented 6 years ago

It would be useful if you could provider header on the column definition as an array and includeHeaders={true} would add/span the applicable cells (they would need to be adjacent in the columns listing).

<MuiTable
  data={data}
  columns={[
    {
      name: 'firstName',
      header: ['Name', 'First'],
    },
    {
      name: 'lastName',
      header: ['Name', 'Last'],
    },
    { name: 'jobTitle', header: 'Job Title' },
  ]}
  includeHeaders={true}
/>