Skip to content

Please provide a DataTable example with nested arrays #4292

@urbgimtam

Description

@urbgimtam

The examples of DataTable are great, but they don't showcase a typical scenario of nested arrays.

Example: structure:

const profile = [
{
  id: 1,
  name: "John",
  tags: [
    'surfer', 'loves nuxt'
  ]
},
{
  id: 2,
  name: "Joe",
  tags: [
    'musician', 'loves vue'
  ]
}, ...
]

In the past I've done the following: placed the 'column' key as 'tags', and then use template slots with {rowData}, then v-for to display each tag. Feels hacky, and also filtering stops working...

Is this the recommended approach?

That's why IMO it is important to improve the docs with an example like this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    docspackages/docs

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions