question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How to show empty state if table array is empty when filter?

See original GitHub issue

Hi there!

In my case I want to show empty state if user search something with input v-model="filter" and found nothing. I see _items is private. Thanks!

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
tmorehousecommented, May 12, 2017

I wonder if a named slot for empty and a slot for emptyFiltered could be created (and conditionally shown based on the length of this._items and/or this.items ?

The conditional slots could be set to have a td with colspan set to of the number of fields available.

It would also be nice to have a named slot for tfoot element (or conditional tfoot). Or an option to repeat the thead fields in the tfoot.

0reactions
tmorehousecommented, May 17, 2017

Should be all fixed is latest master branch.

Read more comments on GitHub >

github_iconTop Results From Across the Web

React Table if Array is empty, no render - Stack Overflow
I have 4 arrays which get data from an API, then i render 4 tables with those arrays, the problem here is, if...
Read more >
Check if an Array is Empty in React | bobbyhadz
To check if an array is empty in React, access its length property, e.g. arr. length . If an array's length is equal...
Read more >
selectedFlatRows is an empty array after filtering #2210 - GitHub
Describe the bug (required) selectedFlatRows becomes empty when filtering selected values yet, selectedRowId are still showing previously ...
Read more >
Examples › Empty state | Mantine DataTable
If records property points to an empty array, the DataTable component will indicate its empty state by displaying a customizable icon and text, ......
Read more >
ISBLANK function in Excel to check if cell is blank - Ablebits
See to use Excel ISBLANK function to identify blank cells and take different actions depending on whether a cell is empty or not....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found