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

Type errors when using Ref<number> for volume #38

Open
chuckntaylor opened this issue May 9, 2023 · 0 comments
Open

Type errors when using Ref<number> for volume #38

chuckntaylor opened this issue May 9, 2023 · 0 comments

Comments

@chuckntaylor
Copy link

I'm likely doing something wrong, or it is an unrelated IDE issue. I am getting an error: Type Ref<number> is not assignable to type '(MaybeRef<number> & number) | undefined when I do the following:

const systemSoundVolume = ref(0.5)
const notification = useSound('url-to-asset', {
volume: systemSoundVolume // error here
})

Any ideas?

For additional context, I manage all the app audio in an audioStore using pinia. So, this is not in the setup function of a component.

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

1 participant