Skip to content

0.1.0

Compare
Choose a tag to compare
@janantala janantala released this 29 Jan 15:06
· 35 commits to master since this release

Usage

var u = new SpeechSynthesisUtterance('Hello World');
u.lang = 'en-US';
u.volume = 1.0;
u.rate = 1.0;
u.onend = function(event) { console.log('Finished in ' + event.elapsedTime + ' seconds.'); };
speechSynthesis.speak(u);

CORS proxy server

u.corsProxyServer = 'http://www.corsproxy.com/';

Supported attributes and methods

SpeechSynthesis Attributes

  • pending
  • speaking
  • paused

SpeechSynthesis Methods

  • speak()
  • cancel()
  • pause()
  • resume()
  • getVoices()

SpeechSynthesisUtterance Attributes

  • text
  • lang
  • voiceURI
  • volume
  • rate
  • pitch

SpeechSynthesisUtterance Events

  • onstart
  • onend
  • onerror
  • onpause
  • onresume
  • onmark
  • onboundary

SpeechSynthesisEvent Attributes

  • charIndex
  • elapsedTime
  • name

SpeechSynthesisVoice

  • voiceURI
  • name
  • lang
  • localService
  • default

Voice depends on google translate service.

SpeechSynthesisVoiceList

  • length
  • item