Skip to content

Instantly share code, notes, and snippets.

@oHervis
Created August 7, 2018 16:47
Show Gist options
  • Save oHervis/d5c8d3578712d799a34acead41b70ba8 to your computer and use it in GitHub Desktop.
Save oHervis/d5c8d3578712d799a34acead41b70ba8 to your computer and use it in GitHub Desktop.
WebSpeech API
import SpeechApi from './SpeechApi';
window.addEventListener('DOMContentLoaded', () => {
if (SpeechApi) {
const speechRecognition = new SpeechTranscription();
speechRecognition.render();
return;
}
document.getElementById('main').innerHTML = 'API não esta disponível';
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment