The track
read-only property of the MediaStreamTrackEvent
interface returns the MediaStreamTrack
associated with this event
The track
read-only property of the MediaStreamTrackEvent
interface returns the MediaStreamTrack
associated with this event
A MediaStreamTrack
object.
js
const stream = new MediaStream(); stream.addEventListener("removetrack", (event) => { console.log(`${event.track.kind} track removed`); });
Desktop | Mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | WebView Android | Chrome Android | Firefox for Android | Opera Android | Safari on IOS | Samsung Internet | |
track |
26 | 12 | 50 | No | 15 | 11 | 4.4 | 26 | 50 | 14 | 11 | 1.5 |
addtrack
and removetrack
eventsMediaStreamTrack
© 2005–2023 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/MediaStreamTrackEvent/track