stackoverflow narrate text js

Solutions on MaxInterview for stackoverflow narrate text js by the best coders in the world

showing results for - "stackoverflow narrate text js"
Franco
19 Nov 2018
1// Narrate some text:
2var msg = new SpeechSynthesisUtterance('Hello world!');
3window.speechSynthesis.speak(msg);
4
5// Cancel the narration:
6window.speechSynthesis.cancel();