Open Mahdi-Sahib opened 7 years ago
hi @ratiw ,
I'm come from jquery, jquery has jquery-datatable plugin, which allows user to "sort" and "search" without any extra remote server requests, since the page has the data already, it should be able to search and sort by itself.
but in vue-table, if user want to sort, developer has to provide handle the sort function in server side, which should be not very productive in some cases.
I guess @Mahdi-Sahib has the similar question like me.
do you have any suggestion on this?
thanks
I find https://github.com/ratiw/vuetable-2/issues/18, which explains the goal of vuetable. I will try vueitems for my case (data size is small and I want to do filter/search on client side).
@zhihuiFan I also came from jquery. In fact, vuetable was actually based on the jquery plugin that I wrote.
The aim for vuetable is only to a presentation layer/component, not to become the data management tool. Based on my experience, loading all of your data and put it into the data presentation layer does not really scale well. It will only work in small project because the data set is small. But for a larger project or when the project needs to grow to handle more data, you will definitely see the problems surfacing up.
For example, the loading time will increase a lot, the component will starts to work a lot slower until you reach the point where you might run out of memory and things break. At the point, you will have to find different techniques to put into your component to keep it working and those techniques are not easy and might cause more problem down the road.
Most apps today usually have data sitting on the server side with a very capable database server underneath exposing its functions through API, so you can ask it to do what it does best.
Now you only need a presentation component to handle the presentation of the data with ease. That's where vuetable is positioned.
Almost all of my projects are CRUD based and I would usually use vuetable on the index page to list the paginated data rows. With thousands or even millions of data on the server side, you could still use vuetable to present them as it only works with a small chuck of data at a time.
Thanks for your detailed explanation and that's definitely true that handling the huge data size in server side is a better way. I think I understand the vue-table wiki page better now:) (why it pays attention on the query params much while other plugin seems doesn't care about that)
@Mahdi-Sahib I'm not sure what you mean. Can you please explain more?