Socket
Book a DemoInstallSign in
Socket

texts-wrapper

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

texts-wrapper

Wrap large pieces of texts by a given width

1.0.0
latest
Source
npmnpm
Version published
Maintainers
1
Created
Source

Texts-Wrapper

Texts-Wrapper is a package that wraps big, chunky texts into smaller texts 👍.

Examples

const textsWrapper = require('texts-wrapper');

const texts = [
    'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed euismod',
    'nunc euismod, euismod nunc euismod, euismod nunc euismod, euismod'
];

console.log(textsWrapper(texts[0], { width: 20 }));
// => Lorem ipsum dolor
// => sit amet,
// => consectetur
// => adipiscing elit. Sed
// => euismod

console.log(textsWrapper(texts[1], { width: 20 }));
// => nunc euismod,
// => euismod nunc
// => euismod, euismod
// => nunc euismod,
// => euismod

console.log(textsWrapper(texts[1], { width: 10 }));
// => nunc
// => euismod,
// => euismod
// => nunc
// => euismod,
// => euismod
// => nunc
// => euismod,
// => euismod

You can only get support in the GitHub repository. Further support will not be given.

Keywords

text

FAQs

Package last updated on 07 May 2022

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

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.