diff --git a/packages/runtime-dom/src/patchProp.ts b/packages/runtime-dom/src/patchProp.ts index 56deb38a57e..e5883d18fca 100644 --- a/packages/runtime-dom/src/patchProp.ts +++ b/packages/runtime-dom/src/patchProp.ts @@ -113,8 +113,11 @@ function shouldSetAsProp( // #8780 the width or heigth of embedded tags must be set as attribute if (key === 'width' || key === 'height') { const tag = el.tagName - return ( - tag === 'IMG' || tag === 'VIDEO' || tag === 'CANVAS' || tag === 'SOURCE' + return !( + tag === 'IMG' || + tag === 'VIDEO' || + tag === 'CANVAS' || + tag === 'SOURCE' ) }