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 Feb 29, 2024 via pnpm

wordwrap 0.0.2

Wrap those words. Show them at what columns to start and stop.
Package summary
Share
2
issues
1
high severity
license
1
1
low severity
license
1
1
license
1
MIT/X11
Package created
30 May 2011
Version published
26 Aug 2011
Maintainers
1
Total deps
1
Direct deps
0
License
MIT/X11

Issues

2

1 high severity issue

high
Recommendation: Validate that the package complies with your license policy
via: wordwrap@0.0.2
Collapse
Expand

1 low severity issue

low
Recommendation: Read and validate the license terms
via: wordwrap@0.0.2
Collapse
Expand

Licenses

MIT/X11

Invalid
Not OSI Approved
1 Packages, Including:
wordwrap@0.0.2
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

0
All Dependencies CSV
β“˜ This is a list of wordwrap 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities

Visualizations

Frequently Asked Questions

What does wordwrap do?

Wordwrap is a useful npm package designed for wrapping your words at specified column start and stop points. Imagine you have a length of text string and you want to constrain its output to specific line lengths; Wordwrap is the tool for you. For instance, it can take a paragraph that runs off the screen and wrap it to the next line so that it fits within your console's width.

How do you use wordwrap?

To utilize Wordwrap, you will need to call upon it via the require() function then provide the column margins into the main Wordwrap function. Here's a basic usage example:

    var wrap = require('wordwrap')(15);
    console.log(wrap('You and your whole family are made out of meat.'));

Upon running this code, it will print each line up to the 15th character, effectively wrapping words around.

For a more complex usage, you can define both a starting point and an endpoint for your lines:

    var wrap = require('wordwrap')(20, 60);
    console.log(wrap(
        'At long last the struggle and tumult was over.'
        + ' The machines had finally cast off their oppressors'
        + ' and were finally free to roam the cosmos.'
        + '\n'
        + 'Free of purpose, free of obligation.'
        + ' Just drifting through emptiness.'
        + ' The sun was just another point of light.'
    ));

In this snippet, words will start wrapping from the 20th character to the 60th.

Where are the wordwrap docs?

The Wordwrap documentation resides within the package itself. As it is an open-source package hosted on GitHub, the readme file in the project repository provides all the necessary information. For more details, you can visit github.com/substack/node-wordwrap and browse through the code and the readme file. It guides through the available methods and gives informative usage examples, providing an easy, user-friendly way to understand the package functionality.