v144 · webrtc
Capability Elements <usermedia> MVP
Usermedia Capability Element, is a declarative, user-activated control for accessing the starting and interacting with media streams.
concepts
-
<usermedia> Element
A declarative <usermedia> element that requests an input device and emits a capture event with the stream. No JS for the common case of 'tap to record'.
-
Microphone Meter
Wire a <usermedia> element to an AnalyserNode and watch live mic levels. Falls back to getUserMedia where the element isn't shipped.
-
Permission UX Compare
Side-by-side: imperative
getUserMediavs declarative<usermedia>. Counts prompts, grants, and denials so you can see why a user-activated control changes the agent's prompting strategy. -
Multi-Source Switcher
Enumerate available cameras with
enumerateDevices(), switch between them live, and inspect the active track's settings — width, height, frameRate, facingMode. The source-switching use case the declarative element enables cleanly.
why it shipped
The current web permission model for interacting with user media relies on JavaScript-triggered prompts, giving the user agent no strong signal of user intent. This results in out-of-context prompts, user frustration, and difficult-to-recover-from denial states.