-
-
Notifications
You must be signed in to change notification settings - Fork 99
Add support for nuxt 3 #715
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
base: main
Are you sure you want to change the base?
Conversation
Hi, thanks for starting this! I do have one question, which I couldn't find a clear answer to in the nuxt docs, is |
Good question. In my understanding this seems to be necessary. Have a look at https://nuxt.new/s/module or at what e.g. VueUse is doing: https://github.com/vueuse/vueuse/tree/main/packages/nuxt. They both import directly from import { defineNuxtPlugin } from '#app' Maybe there will be an import like this as well for Also note that VueUse is releasing a custom package for its nuxt integration, maybe because of that reason. I wonder how they make to module compatible with nuxt 2 and nuxt 3 according to https://modules.nuxtjs.org/?q=vueuse. |
Hi @rigor789 / @WolfgangDrescher, I'm just wondering if either of you guys are still working on support for Nuxt 3? I really enjoyed using this package in my Vue 2 project and am in the process of migrating it to Nuxt 3 and so am really hoping it will have Nuxt 3 support sometime soon. I see there are quite a few others in the Issues also looking for this. Thanks! |
I was not able to improve support for Nuxt 3 for this plugin as I'm not sure how to remove the |
As a workaround you could add https://github.com/rigor789/vue-scrollto/blob/7feaccc327a45b54be93783f245b57ee4fed4448/nuxt3/plugin.js as a nuxt plugin. |
Thanks @WolfgangDrescher, that worked like a charm! |
Todos:
meta.compatibility
to nuxt v3.0.0 once it is releasedVueScrollTo
installation.mjs
file extensions)getSSRProps
error once nuxt v3.0.0 is releasedexports
inpackage.json
(probably a breaking change)