Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on May 16, 2024 via pnpm

stack-utils 2.0.6

Captures and cleans stack traces
Package summary
Share
0
issues
1
license
2
MIT
Package created
4 Jan 2016
Version published
8 Nov 2022
Maintainers
2
Total deps
2
Direct deps
1
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
2 Packages, Including:
escape-string-regexp@2.0.0
stack-utils@2.0.6
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

1
All Dependencies CSV
β“˜ This is a list of stack-utils 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
escape-string-regexp2.0.01.66 kBMIT
prod

Visualizations

Frequently Asked Questions

What does stack-utils do?

Stack-utils is an invaluable helper utility for JavaScript developers that provides capabilities to capture and clean stack traces. Designed to extract crucial information from the node-tap project, stack-utils offers control over what aspects of internal stack trace lines are included or culled, making error handling and debugging smoother and more manageable.

How do you use stack-utils?

In terms of integrating stack-utils in your project, you can easily install it via the npm package manager using the command npm install --save stack-utils. Once installed, it's straightforward to start using stack-utils in your JavaScript code:

const StackUtils = require('stack-utils');
const stack = new StackUtils({cwd: process.cwd(), internals: StackUtils.nodeInternals()});

console.log(stack.clean(new Error().stack));
// outputs a beautified stack trace

In the example above, we import stack-utils, create a new instance of StackUtils with the current working directory (cwd) and the internal node modules (internals) passed as options. We then capture a new Error's stack trace and clean it up using stack.clean method, logging the cleaned up stack trace to the console.

Where are the stack-utils docs?

The document you pasted doesn't mention specific documentation outside of the readme file. However, the most comprehensive source of information for stack-utils is likely its GitHub repository, located at https://github.com/tapjs/stack-utils. This page contains details about the API, usage examples and the project's license. For in-depth understanding and latest updates about stack-utils, this repository should be your go-to reference point. As with any open-source tool, the codebase itself can be another valuable source of information.