utterThis.addEventListener("end", (event) => {
console.log(
`Utterance has finished being spoken after ${event.elapsedTime} seconds.`,
);
});SpeechSynthesisUtterance: end event / notebook
SpeechSynthesisUtterance: end event
Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.
utterThis.onend = (event) => {
console.log(
`Utterance has finished being spoken after ${event.elapsedTime} seconds.`,
);
};