diff --git a/packages/runtime-dom/src/directives/vModel.ts b/packages/runtime-dom/src/directives/vModel.ts index c7dfa40c..90084eed 100644 --- a/packages/runtime-dom/src/directives/vModel.ts +++ b/packages/runtime-dom/src/directives/vModel.ts @@ -79,6 +79,8 @@ export const vModelText: ModelDirective< }, beforeUpdate(el, { value, modifiers: { trim, number } }, vnode) { el._assign = getModelAssigner(vnode) + // avoid clearing unresolved text. #2302 + if ((el as any).composing) return if (document.activeElement === el) { if (trim && el.value.trim() === value) { return