]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
fix: domProps handling
authorEvan You <yyx990803@gmail.com>
Fri, 2 Nov 2018 21:31:54 +0000 (06:31 +0900)
committerEvan You <yyx990803@gmail.com>
Fri, 2 Nov 2018 21:31:54 +0000 (06:31 +0900)
packages/runtime-dom/src/patchData.ts

index 14569f6d6e8c4742d447313b568762179141f497..55aaa3ba0a5c0adf843d6b95c8774584e76bfc1b 100644 (file)
@@ -9,6 +9,7 @@ import { isOn } from '@vue/shared'
 // value, checked, selected & muted
 // plus anything with upperCase letter in it are always patched as properties
 const domPropsRE = /\W|^(?:value|checked|selected|muted)$/
+const domPropsReplaceRE = /^domProps/
 
 export function patchData(
   el: Element,
@@ -34,7 +35,7 @@ export function patchData(
       } else if (domPropsRE.test(key)) {
         patchDOMProp(
           el,
-          key[8].toLowerCase() + key.slice(9),
+          key.replace(domPropsReplaceRE, '').toLowerCase(),
           nextValue,
           prevVNode,
           unmountChildren