Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Generated on Apr 20, 2024 via pnpm

util 0.12.5

Node.js's util module for all engines
Package summary
Share
0
issues
2
licenses
22
MIT
1
ISC
Package created
7 Sep 2011
Version published
16 Oct 2022
Maintainers
6
Total deps
23
Direct deps
5
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
22 Packages, Including:
available-typed-arrays@1.0.7
call-bind@1.0.7
define-data-property@1.1.4
es-define-property@1.0.0
es-errors@1.3.0
for-each@0.3.3
function-bind@1.1.2
get-intrinsic@1.2.4
gopd@1.0.1
has-property-descriptors@1.0.2
has-proto@1.0.3
has-symbols@1.0.3
has-tostringtag@1.0.2
hasown@2.0.2
is-arguments@1.1.1
is-callable@1.2.7
is-generator-function@1.0.10
is-typed-array@1.1.13
possible-typed-array-names@1.0.0
set-function-length@1.2.2
util@0.12.5
which-typed-array@1.1.15

ISC License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
inherits@2.0.4
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

5
All Dependencies CSV
β“˜ This is a list of util 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
inherits2.0.41.98 kBISC
prod
is-arguments1.1.19.64 kBMIT
prod
is-generator-function1.0.1010.21 kBMIT
prod
is-typed-array1.1.137.79 kBMIT
prod
which-typed-array1.1.1539.75 kBMIT
prod

Visualizations

Frequently Asked Questions

What does util do?

Util is a Node.js module meant for use across all engines, even ones that don't inherently support it, such as browsers. It's designed to provide an identical API to the Node.js util module, replicating its functionality for broader compatibility. It's built into Node.js and also included with certain browser bundlers like webpack and browserify. Util is a constructive tool that implements several commonly used processes in Node.js like inheritance, formatting, and inspection.

How do you use util?

Using util is simple and straight-forward, especially if your code runs in Node.js or you are using browser bundlers like webpack or browserify. If not, you will need to install util with npm first by typing npm install util in your shell. After util has been integrated into your development environment, require it at the start of your javascript file with var util = require('util'). Here's a sample usage that demonstrates the functionality of util, in this case, it's used to handle inheritance:

var util = require('util');
var EventEmitter = require('events');

function MyClass() { 
    EventEmitter.call(this);
}

util.inherits(MyClass, EventEmitter);

Note: Promises must be available to use util.promisify and util.callbackify. If you're working with environments like IE11 that do not support Promises, consider using a shim like es6-promise.

Where are the util docs?

The comprehensive documentation for util is maintained on the Node.js website, and can be accessed at https://nodejs.org/docs/latest-v8.x/api/util.html. Due to its nature as a mirror of the original module, any discrepancies or behavioural disparities that are noticed should be reported as issues for resolution. Keep in mind that this adaptation of util is designed to align closely with its Node.js counterpart, and hence, it currently supports the Node 8 LTS API while some of its methods might be outdated.