Skip to content

yoshuawuyts/promise-every

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

promise-every

NPM version build status Test coverage Downloads

Test each value in an array with every and return a Promise.

Installation

$ npm install promise-every

Usage

const every = require('promise-every')

Promise.resolve(['bin', 'baz', 123])
  .then(every((val) => 'string' == typeof val))
// => false

Why?

This module is basically equivalent to Array.every. It's packaged as a single module because it's handy to have the one function you need instead of a kitchen sink. Modularity! Especially handy if you're serving to the browser and need to reduce your javascript bundle size.

Works great in the browser with browserify!

See Also

License

MIT

About

Test each value in an array with every and return a Promise

Resources

License

Stars

Watchers

Forks

Packages

No packages published