TanStack / table

🤖 Headless UI for building powerful tables & datagrids for TS/JS - React-Table, Vue-Table, Solid-Table, Svelte-Table
https://tanstack.com/table
MIT License
24.47k stars 3.03k forks source link

useQwikTable undefined sorting handlers [QwikCity} #5536

Open yigsvnsla opened 1 month ago

yigsvnsla commented 1 month ago

TanStack Table version

8.16.0

Framework/Library version

@tanstack/qwik-table: ^8.16.0

Describe the bug and the steps to reproduce it

Hello everyone, in previous days I have been trying to use the library together with its driver for Qwik and despite certain POC problems, one of the solutions to be able to start the table was downloading the "use" to my Utils folder...

Everything is normal until I find myself needing to use the nice functionalities provided by the table and they do not work as expected...

I try to rely on the documentation and the examples provided in the documentation but these do not work (No Maintenance) without mentioning the other problem that they use an approach only for Qwik + VITE CSR

My problem lies in using the table sorting methods and those are represented as undefined on the browser side since, since they are not serialized, they only stay on the server and do not reflect the client-side instance where the interactive part really is. of the table (code sample uses the SortedRowModel, since in the future I plan to also use it manually)

image

https://tanstack.com/table/latest/docs/framework/qwik/examples/sorting

I would be very happy to update the documentation, example or if in this particular case it is a logic problem... I would appreciate your help

I tried to decipher the serialization and QRL issue on my own but I have problems reflecting the instances and the serialization of the instances to the browser

image

ñ

Your Minimal, Reproducible Example - (Sandbox Highly Recommended)

https://stackblitz.com/edit/qwik-starter-jxfhyv?file=src%2Froutes%2Findex.tsx

Screenshots or Videos (Optional)

image (click in header tags show logs)

Do you intend to try to help solve this bug with your own PR?

No, because I do not know how

Terms & Code of Conduct

KevinVandy commented 1 month ago

I've been asking the qwik team about this particular error in their discord this week. Seems like other setups using the CSR vite setup are running into it, but a fix might be coming from them.

KevinVandy commented 1 month ago

But also, the way this current iteration of the qwik table adapter is setup is somewhat limited. We might be able to offer better integration in v9 by splitting out some of the APIs better.