1.0.2 • Published 6 years ago

fade-promise v1.0.2

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

fade-promise NPM version Build Status

Promisified fade in es6, using requestAnimationFrame

Installation

$ npm install --save fade-promise

Usage

import fadePromise from 'fade-promise';

fadePromise(element, to[, duration]).then((element, to, duration) => {
  console.log('done !');
});

API

The default duration is 300 ms.

fade(el, opacity, duration)

Returns a Promise.

License

MIT © Olivier Gasc