New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

tracedpromise

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tracedpromise

extended promise for tracing all .then calls

latest
Source
npmnpm
Version
0.0.1
Version published
Maintainers
1
Created
Source

tracedpromise

tracedpromise is extended from promise of node.js. You can use it as normal promise. It added a method named "trace" to trace the "caller" of a promise to the end of all ".then" calls. It is useful to log every steps of a promise for a purpose, like an express function responsing an url.

Installation

npm install tracedpromise

Usage

Example:

var TracedPromise = require("tracedpromise");

TracedPromise.trace({msg:"some tracing message"});
new TracedPromise(function(res, rej) {
    // do some thing async
})
.then(function() {
    var traced = TracedPromise.trace();
    console.log(traced.msg);
});

Notice

Be sure to use all methods from tracedpromise, including .then .done .all .race.

License

MIT

Keywords

promise

FAQs

Package last updated on 18 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