tochoromero / vuejs-smart-table

Simple yet powerful Data Table for Vue with vanilla HTML structure
https://tochoromero.github.io/vuejs-smart-table/
MIT License
220 stars 61 forks source link

Vue 3 support? #33

Closed runarberg closed 3 years ago

runarberg commented 4 years ago

I get the following error when I try to use this with Vue 3

[Vue warn]: Unhandled error during execution of scheduler flush. This is likely a Vue internals bug. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/vue-next 
  at <SmartTable class="clusters-table" data= 
Array []
 > 
  at <ClusterTable clusters= 
Array []
 > 
  at <ClustersList onVnodeUnmounted=fn<onVnodeUnmounted> ref=Ref< undefined > > 
  at <RouterView> 
  at <Clusters onVnodeUnmounted=fn<onVnodeUnmounted> ref=Ref< undefined > > 
  at <RouterView> 
  at <App> runtime-core.esm-bundler.js:38
[Vue warn]: Unhandled error during execution of scheduler flush. This is likely a Vue internals bug. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/vue-next 
  at <SmartTable class="clusters-table" data= 
Array [ {…}, {…} ]
 > 
  at <ClusterTable clusters= 
Array [ {…}, {…} ]
 > 
  at <ClustersList onVnodeUnmounted=fn<onVnodeUnmounted> ref=Ref< undefined > > 
  at <RouterView> 
  at <Clusters onVnodeUnmounted=fn<onVnodeUnmounted> ref=Ref< undefined > > 
  at <RouterView> 
  at <App> runtime-core.esm-bundler.js:38
Uncaught (in promise) TypeError: vue__WEBPACK_IMPORTED_MODULE_7__.default is not a constructor
    beforeCreate VTable.vue:57
tochoromero commented 3 years ago

I'm planning on rewriting the plugin with Typescript and Vue 3 support. Hopefully, I will have enough time over the holidays.

mathvicot15 commented 3 years ago

Sorry to ask again, but is there any news about vue 3 support ? This component is really the most clear and simple to use when it comes to tables, so I wait impatiently for your update

tochoromero commented 3 years ago

It is on the works. I did a port to Vue 3 with several improvements, but I'm having some issues with the build process. It is a known problem regarding externalizing Vue.

It shouldn't be long, thank you for your patience.

aznj commented 3 years ago

Hi, what is the latest news on Vue 3 support? Thanks for your effort though.

tochoromero commented 3 years ago

Making very good progress. You can take a look in the next branch.

For the next version I'm keeping all the fundamentals the same but I'm changing all of the internals and some of the APIs to take advantage of the Composition API.

So there are a couple of big items left before I would consider using it on a production app:

Thank you for bearing with me, it makes me very happy to see people actually using the library :)

aznj commented 3 years ago

@tochoromero How to use this in Vue3 ?

tochoromero commented 3 years ago

@tochoromero How to use this in Vue3

I have it working for vue 3 in the next branch, but I just started with the documentation and the API is not completely done.

sasafister commented 3 years ago

Hi, how can I import package in Vue3?

import SmartTable from 'vuejs-smart-table'

this is not working, any tips?

tochoromero commented 3 years ago

@sasafister Vue 3 support is not quite done yet, it is getting close though, please bear with me a little bit more.

tochoromero commented 3 years ago

The next version of Vue Smart Table is coming together pretty nicely. You can give it a try already, though I would not recommend it for production quite yet, but we are getting pretty close though.

The documentation for the next version is here. And it is worth mentioning this works for Vue 2 and Vue 3

aznj commented 3 years ago

@tochoromero pagination is not working yet I presume?

tochoromero commented 3 years ago

@tochoromero pagination is not working yet I presume?

That is the last piece before we have feature parity with the previous version.

I would say it should be ready in the next couple of days.

aznj commented 3 years ago

Hi @tochoromero any news on the pagination? really appreciate your beautiful effort building this for Vue3.

tochoromero commented 3 years ago

@aznj Today I finished pagination, that was the last piece missing. Now it is about polishing, improving the documentation and test it so we can have a stable release.

Thank you all for bearing with me.

tochoromero commented 3 years ago

Typescript support is complete.

At this point all I have left is writing the migration guide and a lot of QA.