Skip to content

Added annyang.isListening() method

Compare
Choose a tag to compare
@TalAter TalAter released this 24 Dec 09:45
· 396 commits to master since this release

Added a new method which returns true if speech recognition is currently on. Returns false if speech recognition is off or annyang is paused.

if (annyang) {
  annyang.isListening(); // will return false
  annyang.start();
  annyang.isListening(); // will return true
  annyang.pause();
  annyang.isListening(); // will return false
  annyang.abort();
  annyang.isListening(); // will return false
}