
Research
/Security News
Fake imToken Chrome Extension Steals Seed Phrases via Phishing Redirects
Mixed-script homoglyphs and a lookalike domain mimic imToken’s import flow to capture mnemonics and private keys.
@lerna-lite/npmlog
Advanced tools
npmlog reimplementation since the original npm/npmlog got deprecatedOn May 4th, 2024, without notice or warning, npm archived a few packages that Lerna-Lite depended on.
The logger util that npm uses.
This logger is very basic. It does the logging for npm. It supports custom levels and colored output.
By default, logs are written to stderr. If you want to send log messages
to outputs other than streams, then you can change the log.stream
member, or you can just listen to the events that it emits, and do
whatever you want with them.
npm install @lerna-lite/npmlog -D
import { log } from '@lerna-lite/npmlog';
// additional stuff ---------------------------+
// message ----------+ |
// prefix ----+ | |
// level -+ | | |
// v v v v
log.info('fyi', 'I have a kitty cat: %j', myKittyCat)
The level to display logs at. Any logs at or above this level will be
displayed. The special level silent will prevent anything from being
displayed ever.
An array of all the log messages that have been entered.
The maximum number of records to keep. If log.record gets bigger than 10% over this value, then it is sliced down to 90% of this value.
The reason for the 10% window is so that it doesn't have to resize a large array on every log entry.
A style object that specifies how prefixes are styled. (See below)
A style object that specifies how the heading is styled. (See below)
If set, a heading that is printed at the start of every line.
process.stderrThe stream where output is written.
Force colors to be used on all messages, regardless of the output stream.
Disable colors on all messages.
Enable the display of log activity spinner and progress bar
Disable the display of a progress bar
Force the unicode theme to be used for the progress bar.
Disable the use of unicode in the progress bar.
Set a template for outputting the progress bar. See the gauge documentation for details.
Select a themeset to pick themes from for the progress bar. See the gauge documentation for details.
Stop emitting messages to the stream, but do not drop them.
Emit all buffered messages that were written while paused.
level {String} The level to emit the message atprefix {String} A string prefix. Set to "" to skip.message... Arguments to util.formatEmit a log message at the specified level.
For example,
Like log.log(level, prefix, message, ...). In this way, each level is
given a shorthand, so you can do log.info(prefix, message).
level {String} Level indicatorn {Number} The numeric levelstyle {Object} Object with fg, bg, inverse, etc.disp {String} Optional replacement for level in the output.Sets up a new level with a shorthand function and so forth.
Note that if the number is Infinity, then setting the level to that
will cause all log messages to be suppressed. If the number is
-Infinity, then the only way to show it is to enable all log messages.
name {String} Optional; progress item name.todo {Number} Optional; total amount of work to be done. Default 0.weight {Number} Optional; the weight of this item relative to others. Default 1.This adds a new are-we-there-yet item tracker to the progress tracker. The
object returned has the log[level] methods but is otherwise an
are-we-there-yet Tracker object.
This adds a new are-we-there-yet stream tracker to the progress tracker. The
object returned has the log[level] methods but is otherwise an
are-we-there-yet TrackerStream object.
This adds a new are-we-there-yet tracker group to the progress tracker. The
object returned has the log[level] methods but is otherwise an
are-we-there-yet TrackerGroup object.
Events are all emitted with the message object.
log Emitted for all messageslog.<level> Emitted for all messages with the <level> level.<prefix> Messages with prefixes also emit their prefix as an event.Style objects can have the following fields:
fg {String} Color for the foreground textbg {String} Color for the backgroundbold, inverse, underline {Boolean} Set the associated propertybell {Boolean} Make a noise (This is pretty annoying, probably.)Every log event is emitted with a message object, and the log.record
list contains all of them that have been created. They have the
following fields:
id {Number}level {String}prefix {String}message {String} Result of util.format()messageRaw {Array} Arguments to util.format()We use set-blocking to set
stderr and stdout blocking if they are tty's and have the setBlocking call.
This is a work around for an issue in early versions of Node.js 6.x, which
made stderr and stdout non-blocking on OSX. (They are always blocking
Windows and were never blocking on Linux.) npmlog needs them to be blocking
so that it can allow output to stdout and stderr to be interlaced.
FAQs
Lerna-Lite npmlog reimplementation of the now deprecated npm/npmlog
The npm package @lerna-lite/npmlog receives a total of 30,649 weekly downloads. As such, @lerna-lite/npmlog popularity was classified as popular.
We found that @lerna-lite/npmlog demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

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.

Research
/Security News
Mixed-script homoglyphs and a lookalike domain mimic imToken’s import flow to capture mnemonics and private keys.

Security News
Latio’s 2026 report recognizes Socket as a Supply Chain Innovator and highlights our work in 0-day malware detection, SCA, and auto-patching.

Company News
Join Socket for live demos, rooftop happy hours, and one-on-one meetings during BSidesSF and RSA 2026 in San Francisco.