Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not working with Vue3 & Vite3 #27

Open
ozgurozalp opened this issue Jul 31, 2022 · 8 comments
Open

Not working with Vue3 & Vite3 #27

ozgurozalp opened this issue Jul 31, 2022 · 8 comments

Comments

@ozgurozalp
Copy link

I only get the error in the image

image

@ozgurozalp ozgurozalp changed the title Not working Vue3 & Vite3 Not working with Vue3 & Vite3 Jul 31, 2022
@tunghsingw
Copy link

same problem

4 similar comments
@mentalrob
Copy link

same problem

@mirzobedil
Copy link

same problem

@HamasakiBrain
Copy link

same problem

@DanielMontilla
Copy link

same problem

@Tahul
Copy link
Member

Tahul commented Nov 25, 2022

Hey @ozgurozalp & @tunghsingw 🙂

I'm very sorry I took so long to answer and fix this issue!

Could you let me know if v2 fixed it for you? I successfully run it with latest Vite and Nuxt 3!

@P-James
Copy link
Contributor

P-James commented Nov 29, 2022

When using a fresh Vite / Vue 3 app (created with Vite CLI). I get the error:
HowlConstructor.value is not a constructor
image

I forked and tried editing line 27 on index.ts from HowlConstructor.value = howler.Howl to HowlConstructor.value = howler.default.Howl, but then I get the same warning mentioned above

image

@P-James
Copy link
Contributor

P-James commented Nov 29, 2022

After some more tinkering, importing onMounted from 'vue' instead of 'vue-demi' fixed the problem.
Is this potentially a Vue bug? I thought they're meant to interact seamlessly 🤔

On index.ts line 2:
import { onMounted, ref, unref, watch } from 'vue'

Edit: have made a PR with some more info #29

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants