The enter event fires when a cue becomes active. In the case of subtitles or a caption this is when it displays over the media.
Use the event name in methods like addEventListener(), or set an event handler property.
addEventListener("enter", (event) => { })
onenter = (event) => { }A generic Event with no added properties.
In the following example, cue prints to the console when it is the active cue.
cue.addEventListener("enter", (event) => {
console.log("Cue 1 has displayed");
});