Help with vue query together vue table
Hi, i need help with my implementation of vue query.
I try to fetch data for my useVueTable data.
The problem is that either it executes the query infinite times or the data is not shown in the table.
and the table is used like this (it is given to a different component):
The datatable is basically the one provided by shadcn vue.
and i also see these errors
Thanks for help
4 Replies
adverse-sapphire•16mo ago
move your ticketQuery usage outside of useVueTable
error you're seeing says exactly that
well, there's obviously type issue in my code, but you should get an idea
rival-blackOP•16mo ago
thanks, it worked. But before i try my next thing, do you know if by using this, i can still use the querry for eg server side pagination, using a custom pagination model like this: https://tanstack.com/table/v8/docs/guide/pagination#manual-server-side-pagination
Pagination Guide | TanStack Table Docs
Examples
Want to skip to the implementation? Check out these examples:
adverse-sapphire•16mo ago
i haven't worked with pagination in tanstack table yet, it should absolutely work though
keep in mind that your
ticketQuery
is breaking reactivity right now by not using ref
for page number
rival-blackOP•16mo ago
i haven't worked with pagination in tanstack table yet, it should absolutely work thoughOk thanks