Text2Speech JS
Wrapper around browser Text to Speech API
Note: This package use HTML5 Web Speech API. So, make sure your browser is supported. Please take a look here to see all the supported browser Can I Use Speech Synthesis
Example
Check out this link Text to Speech Example
Installation
Install using one of these method below
yarn add text2speech-js # or npm install text2speech-js
Then you can import it using this way:
const Text2Speech = // or
You can also attach directly to your HTML file by using this way:
Usage
const tts = ttstext = "Hello World!" // Speaktts // Pausetts // Resumetts // Stoptts
Options
See all the available config here: SpeechSynthesisUtterance Properties
License
MIT Copyright (c) 2019 - Jefry Dewangga(@jefrydco)