promise-inverter
v0.1.0
Published
Rejects resolved promises and vice versa.
Downloads
2
Readme
js-promise-inverter
Rejects resolved promises and vice versa.
Usage
npm install promise-inverter
const invertPromise = require('promise-inverter');
invertPromise(Promise.resolve()); // This will return a rejected promise.
invertPromise(Promise.reject()); // This will return a resolved promise.
Testing
npm test