0.0.3 • Published 7 years ago

simplayer-promise v0.0.3

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

About

This is simple multi platform sound player. I get ideas from opener.

This module should be used when to play simple sound or sound effect. Not suitable for music players.

Installation

npm install simplayer-promise --save

If platform is linux, then need to install the alsa

# before we start the work, please update
sudo apt-get update
sudo apt-get upgrade

# install ALSA
sudo apt-get install alsa-base alsa-utils

Usage

simplayer-promise function return Promise instance.

var play = require('simplayer-promise');

play('/path/to/sound.mp3')
  .then(() => {
    // something
  })
  .catch(() => {
    // reject
  });

Author

  • Maxmellon

LICENSE

MIT