Donmclean
10/4/2016 - 1:55 PM

Speech Synthesis for web

Speech Synthesis for web

function speak (message) {
  var msg = new SpeechSynthesisUtterance(message)
  var voices = window.speechSynthesis.getVoices()
  msg.voice = voices[0]
  window.speechSynthesis.speak(msg)
}

speak('hello');