Media preload defaults to metadata Sample

Available in Chrome 64+ | View on GitHub | Browse Samples

Background

Chrome now sets the default preload value for <video> and <audio> elements to metadata in order to reduce bandwidth and resource usage. This new behaviour only applies to cases where no preload value is set. Note that the preload attribute's hint is still ignored when a MediaSource is attached to the media element.

Credits: Media files are © copyright Blender Foundation | www.blender.org .

<video>
<video preload="auto">

Live Output


JavaScript Snippet

const videowithNoPreload = document.querySelector('#videoWithNoPreload');
const videowithAutoPreload = document.querySelector('#videoWithNoPreload');

log('               <video> preload value is ' + videoWithNoPreload.preload);
log('<video preload="auto"> preload value is ' + videoWithAutoPreload.preload);