I noticed that using an audio file in <video>
works fine.
Does this feature have good browser compatibility and is it an HTML5 standard?
I found this but it's from 7 years ago and has no answers.
CodePudding user response:
Yes a <video>
element is supposed to be able to play media resources that only contain audio data, just like an <audio>
element is supposed to be able to play video media (without displaying the video stream).
A browser that wouldn't do that would be a buggy browser.
CodePudding user response:
<video>
tag supports most browsers like chrome, edge, firefox, safari, and opera.
It is a global attribute in HTML5.
For Audio you can also use <audio>
.
If you want to know more there is something you can check out https://www.w3schools.com/tags/tag_video.asp