morsejs-render-vibration

0.1.1 • Public • Published

morsejs-render-vibration

npm version Build Status Inline docs

A plugin for morsejs to vibrate a device in timing with a morse code message using the HTML Vibration API.

Installation

Dependency

npm install --save morsejs-render-vibration

Usage

var morsejs = require("morsejs"),
    morsejsRenderVibration = require("morsejs-render-vibration"),
    translatedMessage = morsejs.translate("hello");
 
/* 
 * Be sure to check that vibration is supported before 
 * you start tring to vibrate the device
 */
if(morsejsRenderVibration.isVibrationSupported()){
    morsejsRenderVibration.vibrateMorse(translatedMessage);
}

Readme

Keywords

Package Sidebar

Install

npm i morsejs-render-vibration

Weekly Downloads

2

Version

0.1.1

License

MIT

Last publish

Collaborators

  • zero298