Rush StackShopBlogEvents
Skip to main content

Home > @rushstack/terminal > PrintUtilities

PrintUtilities class

A collection of utilities for printing messages to the console.

Signature:

export declare class PrintUtilities 

Methods

Method

Modifiers

Description

getConsoleWidth()

static

Returns the width of the console, measured in columns

printMessageInBox(message, terminal, boxWidth)

static

Displays a message in the console wrapped in a box UI.

wrapWords(text, maxLineLength, indent)

static

Applies word wrapping.

wrapWords(text, maxLineLength, linePrefix)

static

Applies word wrapping.

wrapWords(text, maxLineLength, indentOrLinePrefix)

static

Applies word wrapping.

wrapWordsToLines(text, maxLineLength, indent)

static

Applies word wrapping and returns an array of lines.

wrapWordsToLines(text, maxLineLength, linePrefix)

static

Applies word wrapping and returns an array of lines.

wrapWordsToLines(text, maxLineLength, indentOrLinePrefix)

static

Applies word wrapping and returns an array of lines.