The read-only VideoTrackList
property selectedIndex
returns the index of the currently selected track, if any, or -1
otherwise.
VideoTrackList.selectedIndex
Value
A number indicating the index of the currently selected track, if any, or -1
otherwise.
Specifications
Specification |
---|
HTML Standard # dom-videotracklist-selectedindex-dev |
Browser compatibility
Desktop | Mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | WebView Android | Chrome Android | Firefox for Android | Opera Android | Safari on IOS | Samsung Internet | |
selectedIndex |
37
|
79
12-79
|
33
|
10
|
24
|
7
|
No
|
37
|
No
|
24
|
7
|
No
|
© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/VideoTrackList/selectedIndex