I am seeing a network
error when I am trying to use the SpeechRecognition API in Brave. It's working just fine in Chrome and Safari in OS X. Is that simply not working in Brave or is there a way to make it work? Please have a look at the jsfiddle below for a 'working' example. I would have expected SpeechRecognition || webkitSpeechRecognition
to be undefined
if Speech Recognition is not supported.
var SpeechRecognition = SpeechRecognition || webkitSpeechRecognition
var recognition = new SpeechRecognition();
recognition.lang = "en-US";
recognition.continuous = true;
recognition.interimResults = true;
recognition.start();
recognition.onresult = function(event) {
document.getElementById("text").innerHTML += event.results[0][0].transcript;
}
recognition.onstart = function(event) {
document.getElementById("text").innerHTML += '-start-' ;
}
recognition.onerror = function(event) {
document.getElementById("text").innerHTML += `-error ${event.error}-` ;
}
recognition.onend = function(event) {
document.getElementById("text").innerHTML += '-end-' ;
}