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

benchjs

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

benchjs

BenchJS is a simple Node.js library that helps you benchmark the execution time inside your programs.

latest
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

BenchJS

BenchJS is simple benchmark time track Node.js library

The following snippet:

var bench = require('benchjs');

// Benchmark the time between executions
var start = bench.mark();
setTimeout(function() {
    var time = bench.mark(start);
    console.log(time);
}, 2000);

Will print:

{
    nanoseconds: 5480017,
    microseconds: 5480,
    milliseconds: 5,
    seconds: '02',
    minutes: '00',
    hours: '00',
    time: '00:00:02.5',
    message: '[00:00:02.5]'
}

Installation

$ npm install -s benchjs

Contributing

This package is under development. Pull requests are welcomed.

People

The current lead maintainer is Hugo Santos

License

ISC

Keywords

bench

FAQs

Package last updated on 15 May 2017

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