Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

countn

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

countn

Simple control flow, for counting callbacks

  • 1.0.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
7
increased by250%
Maintainers
1
Weekly downloads
 
Created
Source

countn

countn is a simple control flow for counting callbacks.

Build Status

Installation

$ npm install countn

Usage Example

Here is a example of simple async scheduling. Where we have subscribed to execute some code after all concurent tasks have finished.

var countn = require('countn')
var cb = countn(5, function() {
  console.log('we are done')
})

setTimeout(cb, 300)
setTimeout(cb, 100)
setTimeout(cb, 500)
setTimeout(cb, 200)
setTimeout(cb, 400)

What's it good for?

countn is not ment to replace any control flow library, rather as i am still counting callbacks, i just wanted a simple library for a little suggar on top of it.

Running tests

$ npm install $ npm test

Authors

  • dejanr

License

MIT

FAQs

Package last updated on 09 Aug 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc