Enable Web Speech API on Mozilla Firefox

自作多情 提交于 2019-12-22 04:46:25

问题


I've been working with the voice/speech synthesis on Chrome and then I realized Firefox doesn't allow it by default and special permissions must be granted.

By reading this article I could make the test work:

https://developer.mozilla.org/en-US/docs/Web/API/Web_Speech_API/Using_the_Web_Speech_API

Firefox desktop and mobile support it in Gecko 44+, without prefixes, and it can be turned on by flipping the media.webspeech.recognition.enable flag to true in about:config. The permissions settings/UI haven't yet been sorted out however, so permission can't be granted to use it by the user, so it can't be used. This will be fixed soon.

The test is in this link:

http://mdn.github.io/web-speech-api/speak-easy-synthesis/

But I wonder how I could allow it on my client's browser when they go to my app? How do we ask for different permissions and allow, for example, media.webspeech.synth.enabled?


回答1:


As an update, Speech Synthesis is enabled in Firefox 49+ (2016-09).

Work on exposing Speech Recognition to the web is ongoing as of 2019 (see bug 1248897)

https://caniuse.com/#search=speech



来源:https://stackoverflow.com/questions/38529098/enable-web-speech-api-on-mozilla-firefox

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!