uiv-lib / uiv

Bootstrap 3 components implemented by Vue.js.
https://uiv.wxsm.space
MIT License
944 stars 182 forks source link

Will be this lib supported by Vuejs 3? #473

Closed djom202 closed 2 years ago

djom202 commented 3 years ago

I just want to know if it will be supported by vuejs v3 to know if I should change of framework or I just need to wait.

Thanks so much!

wxsms commented 3 years ago

TLDR: What you need might be Bootstrap 4/5, not 3.

I dont think that there's a reason that this lib has to support Vue.js 3, because when you use Bootstrap 3 you typically want some compitable with old fasion browsers, which was dropped by Vue.js 3.x.

djom202 commented 3 years ago

Hi @wxsms, I'm trying to use UIV with Vuejs v3 app, and as you says "Bootstrap 3 Components implemented by Vue 2", so I'm supposing that it's not works with Vue v3 apps, nevertheless I tried to use it, so I got an issue related to v3 changes as you can see below:

import * as uiv from 'uiv'
import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'

// Vue
createApp(App)
  .use(store)
  .use(router)
  .use(uiv)
  .mount('#app')

// Error: "export 'default' (imported as 'Vue') was not found in 'vue'
wxsms commented 3 years ago

it's resonable, because there're some Vue usaeges inside the lib, which may compitable with v2 only at this time.

Aston13 commented 3 years ago

I have this same question - I have been using this library a lot with Vue 2 applications and I am hoping to upgrade to Vue 3 this year. If this library doesn't work with Vue 3 then perhaps it is not a good idea I continue to use it :(?

wxsms commented 3 years ago

contribution is welcome.

mbokil commented 3 years ago

I would suggest holding off on modifying this library for Vue 3. Looks like Vue 2.7 will be released with Vue 3.0 composition API features and IE11 compatibility since the RFC has gone forward. I would test UIV when the beta of Vue 2.7 is released to ensure compatibility.

0x0dr1y commented 3 years ago

@wxsms I‘d love to tackle the upgrade to Vue 3, since i heavily rely on uiv. How do you normally spin up a dev env for uiv? I saw that yarn dev isn‘t working due to missing files

wxsms commented 3 years ago

@wxsms I‘d love to tackle the upgrade to Vue 3, since i heavily rely on uiv. How do you normally spin up a dev env for uiv? I saw that yarn dev isn‘t working due to missing files

@MrDeerly The dev command is not using any more (I forgot to remove it), since the demo documents are in in an other repo (but you may also clone them both and link the uiv dist of document to the dev one). I use unit tests for development mainly. it covers most case. how ever, it's a bit slow, since it's relying on puputeer to run. I may migrate it to jest sometimes in the future.

wxsms commented 2 years ago

I just:

  1. migrated the testing framework to jest, for faster test
  2. migrated back the docs into this repo, so we have a demo website with dev script
  3. created a vue3 branch, and do some basic works (vitepress, rollup, eslint, ect)

but there're still lots of works to do if you guys needed a working vue3 version. basicly:

  1. fix all the import Vue usage https://v3.vuejs.org/guide/migration/global-api.html#a-new-global-api-createapp
  2. change all functional components back to normal sfc, or follow the new v3 syntax https://v3.vuejs.org/guide/migration/functional-components.html
  3. change portal-vue usage to vue teleport https://v3.vuejs.org/guide/teleport.html#teleport
  4. fix any vue3 incompatible api change
  5. fix testing

since I'm not using this lib anymore, I don't have much motivation to do this. if any one interesting on it, pls let me know, and start you work on a fork maybe. after you finished like 80% of works, I will be happy to merge it, and invite you as a member of this org to continue your work if you wish to. Thanks!

wxsms commented 2 years ago

I'm working on it.

wxsms commented 2 years ago

https://github.com/uiv-lib/uiv/releases/tag/v2.0.0-alpha.0 is ready for Vue 3.