From 4a900f19e7670e97b3c156cd30c1e18ec292d198 Mon Sep 17 00:00:00 2001 From: Sam Dallstream Date: Thu, 23 May 2019 14:53:18 -0700 Subject: [PATCH] Added charLength and name to SpeechSynthesisEvent features that are printed to console. --- speechsynthesis/scripts/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/speechsynthesis/scripts/index.js b/speechsynthesis/scripts/index.js index 9b3b71a6..1ef00fb5 100755 --- a/speechsynthesis/scripts/index.js +++ b/speechsynthesis/scripts/index.js @@ -84,7 +84,7 @@ const eventList = ['start', 'end', 'mark', 'pause', 'resume', 'error', 'boundary']; eventList.forEach((event) => { synUtterance.addEventListener(event, (speechSynthesisEvent) => { - log(`Fired '${speechSynthesisEvent.type}' event at time '${speechSynthesisEvent.elapsedTime}' and character '${speechSynthesisEvent.charIndex}'.`); + log(`Fired '${speechSynthesisEvent.type}' event named '${speechSynthesisEvent.name}' at time '${speechSynthesisEvent.elapsedTime}' and character '${speechSynthesisEvent.charIndex} of length '${speechSynthesisEvent.charLength}.`); }); });