nano-performance
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

nano-performance

An extremely lightweight node module that measures execution time in nanoseconds.

Created by Agilit-e

Installation

Using npm:

npm install nano-performance

Display output in milliseconds (default):

import { timeStart, timeEnd } from "nano-performance";

timeStart("Test");

setTimeout(function () {
  timeEnd("Test");
}, 10);

Output = Test: 11.086301 ms

Display output in nanoseconds:

import { timeStart, timeEnd } from "nano-performance";

timeStart("Test");

setTimeout(function () {
  timeEnd("Test", "ns");
}, 10);

Output = Test: 11086301 ns

Dependents (1)

Package Sidebar

Install

npm i nano-performance

Homepage

agilite.io

Weekly Downloads

14

Version

1.0.1

License

MIT

Unpacked Size

7.14 kB

Total Files

13

Last publish

Collaborators

  • agilite