Why does a <video> stop playing when removed from the DOM, while it can still play detached?
问题 I was working on a custom component and stumbled upon this strange behavior. Basically, it is possible to play a video file without adding a <video> element to the DOM at all. const video = document.createElement('video'); video.src = "https://upload.wikimedia.org/wikipedia/commons/transcoded/c/c6/Video_2017-03-19_23-01-33.webm/Video_2017-03-19_23-01-33.webm.480p.webm"; function start() { if (video.paused) { video.play(); console.log('paused', video.paused); } } <div><button onclick='start()'