ethereumjs-monorepo

@ethereumjs/util


@ethereumjs/util / short

Function: short()

short(bytes, maxLength?): string

Defined in: packages/util/src/bytes.ts:297

Truncate a hex string or bytes display for logging.

Parameters

bytes

string | Uint8Array<ArrayBufferLike>

maxLength?

number = 50

Maximum visible characters excluding the ellipsis (default 50)

Returns

string