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

node-later

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-later

Defer function calls to the start of the next cycle.

  • 2.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

node-later

NPM Version CI Coverage Status Known Vulnerabilities Inline docs License Total Downloads

Defer function calls to the start of the next cycle.

Overview

Invoke functions in the next cycle.
You have multiple node.js APIs to run a function later, for example process.nextTick, setImmediate and setTimeout.
Each of those will invoke the provided function at a different time.
This library enables to extract the "best" API which enables to run a provided function as soon as possible based on the currently node.js runtime version.

Usage

//first you must require this library as follows:
var later = require('node-later');

//get a defer function based on current node.js version
var defer = later();

//or get a defer function based on a specific node.js version
defer = later('0.10.0'); //let be compatible with node.js 0.10 regardless of our current node.js runtime

//or get a defer function which is IO safe (will prevent stack overflow errors)
defer = later(true);

//use defer function
defer(onCallback() {
  //do something
});

Installation

In order to use this library, just run the following npm install command:

npm install --save node-later

API Documentation

See full docs at: API Docs

Contributing

See contributing guide

Release History

DateVersionDescription
2020-05-11v2.0.0Migrate to github actions and upgrade minimal node version
2019-12-16v1.0.16Maintenance
2017-04-28v1.0.0Offical release
2017-04-28v0.0.1Initial release

License

Developed by Sagie Gur-Ari and licensed under the Apache 2 open source license.

Keywords

FAQs

Package last updated on 11 May 2020

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