Socket
Socket
Sign inDemoInstall

@types/wrap-ansi

Package Overview
Dependencies
0
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/wrap-ansi


Version published
Weekly downloads
1.7M
decreased by-4.13%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

Installation

npm install --save @types/wrap-ansi

Summary

This package contains type definitions for wrap-ansi (https://www.npmjs.com/package/wrap-ansi).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/wrap-ansi.

index.d.ts

/**
 * Wrap words to the specified column width.
 *
 * @param input   String with ANSI escape codes. Like one styled by chalk.
 * @param columns Number of columns to wrap the text to.
 * @param options By default the wrap is soft, meaning long words may extend past the column width. Setting
 *                this to true will make it hard wrap at the column width.
 */
declare function wrapAnsi(input: string, columns: number, options?: wrapAnsi.Options): string;

declare namespace wrapAnsi {
    interface Options {
        /** @default false */
        hard?: boolean | undefined;
        /** @default true */
        trim?: boolean | undefined;
        /** @default true */
        wordWrap?: boolean | undefined;
    }
}

export default wrapAnsi;

Additional Details

  • Last updated: Wed, 18 Oct 2023 18:04:04 GMT
  • Dependencies: none

Credits

These definitions were written by Klaus Reimer, and Piotr Błażejewicz.

FAQs

Last updated on 18 Oct 2023

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

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc