🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
DemoInstallSign in
Socket

bol

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bol

Currently just a wrapper around speechSynthesis with slightly better consistency in voices, Trying to be super consistent! Text-to-speech for Web.

0.1.6
latest
Source
npm
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

Bol (बोल) 🗣

TTS Library for Web

Currently just a wrapper around speechSynthesis with slightly better consistency in voices, Trying to be super consistent! Text-to-speech for Web.

npm

Meant to be used on frontend.

NOT READY FOR PROD

If you still want to ruin your life, here's how you can do it:

Installation

npm install --save bol

or

<script src="https://unpkg.com/bol@^0/dist/bol.min.js"></script>

Usage

ES Module

import Bol from 'bol';

const bol = new Bol("UK English Female", {rate: .8, pitch: 1, volume: 1})

bol.speak("Whhatta useless package", "UK English Male")
  .then(elapsedTime => console.log(elapsedTime))

or

Vanilla Script Include

<body>
  <button class="talk">Fact of the Day</button>
  <script src="https://unpkg.com/bol@^0/dist/bol.min.js"></script>
  <script>
    const bol = new Bol('UK English Male', {rate: .8});

    document.querySelector('.talk').addEventListener('click', e => {
      bol.speak("HTML is a programming language!")
        .then(elapsedTime => {
          console.log(elapsedTime);
        })
    })
  </script>
</body>

Make sure you wrap bol.speak around a user's touch, swipe, click handlers to make it work.

Voices

  • "UK English Male"
  • "UK English Female"
  • "US English Male"
  • "US English Female"

Me!

🌻

FAQs

Package last updated on 17 Mar 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts