Skip to content

Commit 6b30c17

Browse files
committed
fix #305
1 parent 58fbb50 commit 6b30c17

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-tippy",
3-
"version": "6.4.0",
3+
"version": "6.4.1",
44
"main": "index.js",
55
"module": "dist/vue-tippy.mjs",
66
"unpkg": "dist/vue-tippy.iife.js",

src/composables/useTippy.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,9 @@ export function useTippy(
6767
if (!headlessApp.value) {
6868
headlessApp.value = createApp({
6969
name: settings.appName,
70-
render: () => unwrappedContent,
70+
setup: () => {
71+
return () => isRef(content) ? content.value : content
72+
},
7173
})
7274

7375
if (vm) {
@@ -79,12 +81,11 @@ export function useTippy(
7981
newContent = () => getContainer()
8082
} else if (typeof unwrappedContent === 'object') {
8183
if (!headlessApp.value) {
82-
83-
let comp = h(unwrappedContent)
84-
8584
headlessApp.value = createApp({
8685
name: settings.appName,
87-
render: () => comp,
86+
setup: () => {
87+
return () => h(isRef(content) ? content.value : content as any)
88+
},
8889
})
8990

9091
if (vm) {

0 commit comments

Comments
 (0)