Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to clear/empty vuetable rows ? #158

Open
jorwan opened this issue May 8, 2017 · 1 comment
Open

How to clear/empty vuetable rows ? #158

jorwan opened this issue May 8, 2017 · 1 comment

Comments

@jorwan
Copy link

jorwan commented May 8, 2017

Hi, thanks for this great component

I would like to empty vuetable on response with errors as 404, or 500, etc

And for any other case, i would like to know how to empty/clear the vuetable rows ?

Thanks

@ratiw
Copy link
Owner

ratiw commented May 9, 2017

Use v-ref to create a reference to your vuetable, then set the tableData to empty array [], like so

<vuetable v-ref="vuetable"></vuetable>
this.$refs.vuetable.tableData = []

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants