euvl / vue-js-modal

Easy to use, highly customizable Vue.js modal library.
http://vue-js-modal.yev.io
MIT License
4.35k stars 592 forks source link

For anyone who wants to keep using this repo in vue3 project. #814

Open imndx opened 5 months ago

imndx commented 5 months ago

The following is all you need to use this plugin in your vue3 project, especially for those project migrated from vue2.

  1. clone this repo
  2. apply the attached patch
  3. copy the source code to your project
  4. npm install --save resize-observer-polyfill
  5. npm uninstall vue-js-modal
  6. import your local vue-js-modal instead of the original 'vue-js-modal'
  7. none

vue3.patch

pzpsofficial commented 3 months ago

Hi @imndx, which node version did you use to build the project with patched code?

pzpsofficial commented 3 months ago

Also the patched code uses createVNode function, which was replaced by h in Vue 3. What am I missing?

wloszynski commented 3 months ago

bump

imndx commented 3 months ago

Hi @imndx, which node version did you use to build the project with patched code?

18.9.0

Aliozzaim commented 2 weeks ago

If you’re still having issues adapting this modal to Vue 3, please take a look at this article: Fixing vue-js-modal for Vue 3: A Guide to Restoring Modal Functionality.

rangermeier commented 1 week ago

If you’re still having issues adapting this modal to Vue 3, please take a look at this article: Fixing vue-js-modal for Vue 3: A Guide to Restoring Modal Functionality.

Thanks for the write-up. It would be awesome if you could publish a fork on Github with the changes detailed in your article!