The srcObject attribute allows associating a MediaStream to a media element using a simple assignment. Previously, achieving this required first obtaining a URL associated to the MediaStream, and then associating this URL to the media element.

Documentation

Specification

Specification link


Final published standard: Recommendation, Living Standard, Candidate Recommendation, or similar final form

Status in Chromium

Blink


Enabled by default (tracking bug)

Consensus & Standardization

After a feature ships in Chrome, the values listed here are not guaranteed to be up to date.

Owners

Comments

The spec specifies that it must be possible assign MediaStream, MediaSource or Blob objects to the srcObject attribute. However, Blink will initially support only MediaStream objects. All other browsers provide support only for MediaStream as well.

Last updated on 2020-11-09