Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@rollup/log
Advanced tools
🌳
A logger that provides targeted log levels and display options.
Note: This module requires Node 8.11.0.
Using npm:
$ npm install @rollup-cabal/log
Using yarn:
$ yarn add @rollup-cabal/log
import { logger } from '@rollup-cabal/log';
const log = logger()
log.info('batman');
//→ ⓡ batman
Each log instance is unique by default. To persist an instance and
fetch it elsewhere, provide an id
property on options
.
Type: object
Type: string
A unique identifier for a log instance.
Type: string
Default: info
Values: trace
debug
info
warn
error
The minimum log level to display output for. Output for levels above the set level will be displayed. Log levels shown in Values above are in order of lowest to highest.
Setting a level of 'info'
will display output for log.info
,
log.warn
, and log.error
. Setting a level of 'error'
will display output
only for log.error
.
Type: string
Text to display before each log message.
import { logger } from '@rollup-cabal/log';
const log = logger({ preface: '⋊ batcave ⋉' });
log.info('batman');
//→ ⓡ ⋊ batcave ⋉ batman
Type: string
Default: boolean
Set to true
to display a timestamp before each log message.
import { logger } from '@rollup-cabal/log';
const log = logger({ timestamp: true });
log.info('batman');
//→ [00:00:00] ⓡ batman
Type: Array[string]
Default: ['info', 'warn', 'error', 'pass', 'fail']
Defines the levels which output to stderr
by default. This setting is useful
for directing select loggers to output only specific levels to stderr
while
allowing other levels to output to stdout
.
import { logger } from '@rollup-cabal/log';
const log = logger({ stderr: ['warn', 'error'] });
log.info('batman');
// stdout → ⓡ batman
log.warn('riddler');
// stderr → ⓡ riddler
string
)Displays output to stderr
prefaced with ⓡ
colored blue. Akin to
console.log
.
string
)Displays output to stderr
prefaced with ⓡ
colored yellow.
string
)Displays output to stderr
prefaced with ⓡ
colored red.
string
)Displays output to stdout
prefaced with ⓡ
colored magenta.
string
)Displays trace output akin to console.trace
to stdout
prefaced with ⓡ
colored cyan.
string
)Displays output to stderr
prefaced with ⓡ
colored green. The output is
persisted regardless of the set level
.
string
)Displays output to stderr
prefaced with ⓡ
colored red. The output is
persisted regardless of the set level
.
FAQs
We found that @rollup/log demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers 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
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.