Skip to content

Commit 2fe6386

Browse files
committed
fix v-text
1 parent 172d82f commit 2fe6386

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/directives/text.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import { isObject } from '@vue/shared'
22
import { Directive } from '.'
33

4-
export const text: Directive<Text> = ({ el, get, effect }) => {
4+
export const text: Directive<Text | Element> = ({ el, get, effect }) => {
55
effect(() => {
6-
el.data = toDisplayString(get())
6+
el.textContent = toDisplayString(get())
77
})
88
}
99

0 commit comments

Comments
 (0)