ImageTrackList: selectedIndex property
MDN Web Docs · نسخهٔ df622a2a1c1e · CC BY-SA 2.5 و مجوز جداگانهٔ ناشر برای نمونهکد
{{APIRef("WebCodecs API")}}{{AvailableInWorkers("window_and_dedicated")}}
The **selectedIndex** property of the {{domxref("ImageTrackList")}} interface returns the index of the selected track.
Value
An integer.
Examples
The following example prints the value of selectedIndex to the console.
js
let tracks = imageDecoder.tracks;
console.log(tracks.selectedIndex);Specifications
{{Specifications}}
Browser compatibility
{{Compat}}