#Web Speech API

8 messages · Page 1 of 1 (latest)

worthy ferry
#

Has anyone managed to get the web speech api working in a Tauri window? I'm getting a "Uncaught (in promise) DOMException: Failed to load because no supported source was found." when trying create a new SpeechSynthesisUtterance. Is there some allowlist config I need to enable to get this to work?

           utterance = new SpeechSynthesisUtterance(text);
           utterance.voice = synth.getVoices()[0];
           utterance.rate = 0.8;
            
           synth.speak(utterance);```
proud cipher
#

If it does, all webviews might not well support it

worthy ferry
#

If I use an external URL with the same code, it plays in the Tauri webview. But a static html file in Tauri fails.

soft raven
#

If you’re on mac you will probably have to turn it on in entitlements

worthy ferry
soft raven