Get the default state of the track:
The result of x could be:
The default property sets or returns the default state of the track.
This property reflects the <track> default attribute.
When present, it specifies that the track is to be enabled if the user's preferences do not indicate that another track would be more appropriate.
Note: There must not be more than one track element with a default attribute per media element.
The default property is supported Internet Explorer, Opera, and Chrome.
Note: The default property is not supported in Firefox, Safari or Internet Explorer 9 and earlier versions.
Return the default property:
Set the default property:
Value | Description |
---|---|
true|false |
Specifies the default state of the track
|
Return Value: | A Boolean, representing the default state of the track |
---|
Set the default state of the track:
HTML reference: HTML <track> default attribute