We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I take a look on the way tippy is used in Composition API, and I wondering if it could be simplified ?
Instead of creating and passing a target ref like:
<template> <button ref="btn">Tippy!</button> </template> <script setup> import { useTippy } from 'vue-tippy' import Counter from '@components/Counter.vue' const btn = ref() useTippy(btn, { content: h(Counter, { initialCount: 42 }), arrow: true, }) </script>
... take the target returned by the composable and pass it to the dom:
<template> <button ref="btn">Tippy!</button> </template> <script setup> import { useTippy } from 'vue-tippy' import Counter from '@components/Counter.vue' const { target: btn } = useTippy({ content: h(Counter, { initialCount: 42 }), arrow: true, }) </script>
The composable would be responsible to create the ref, then reassigned by Vue on mounting.
What do you think?
The text was updated successfully, but these errors were encountered:
maybe like this?
const { target: btn } = useTippy({ content: h(Counter, { initialCount: 42 }), arrow: true, })
Sorry, something went wrong.
Yes sorry, I forgot to remove the btn param
No branches or pull requests
I take a look on the way tippy is used in Composition API, and I wondering if it could be simplified ?
Instead of creating and passing a target ref like:
... take the target returned by the composable and pass it to the dom:
The composable would be responsible to create the ref, then reassigned by Vue on mounting.
What do you think?
The text was updated successfully, but these errors were encountered: