DOM Properties
HTMLVideoElement.videoWidth
Read-only. Reports the intrinsic video width in CSS pixels, or zero when the intrinsic dimensions are not yet known. Do not use it as the element's CSS layout width. Example result: 0.
Formal Syntax & Structure
html syntaxhtml
element.videoWidthReturn Value
number
Property value. Read-only.
Working Example
Example Snippethtml
<video id="demo" width="320"></video><p> Result: <output id="result"></output></p><script> const e = document.getElementById('demo'); const result = value => { document.getElementById("result").textContent = String(value); }; result(e.videoWidth);</script>