Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
chroma-palette
Advanced tools
A light-weight utility for coloring your terminal. 0 dependencies. Default is a preselected color output from the 256 color palette, chosen to enhance legibility.
A light-weight utility for coloring your terminal. 0 dependencies. Default is a preselected color output from the 256 color palette, chosen to enhance legibility.
npm i chroma-palette
Default is a preselected color output from the 256 color palette, chosen to enhance legibility.
const chroma = require('chroma-palette')
// chaining
console.log(
chroma.blue.whiteBg.bold.paint('Hello world!')
);
// combine
console.log(
chroma.blue.paint('Hello ') + chroma.bold.paint('world') + '!'
);
// template literal
console.log(
`${chroma.blue.paint('Hello')} ${chroma.bold.paint('world')}!`
);
If you need to alter the output of the colors to support the 16-color set.
const { Chroma } = require('chroma-palette')
// change profile to 16
const chroma = new Chroma({ profile:'16' })
// output will be the cyan from the 16-color palette
console.log(
chroma.cyan.paint('Hello world!')
);
If you want to change the output of various colors.
const { Chroma } = require('chroma-palette')
// change any color by { [COLOR]:'[NUMBER FROM 256]' }
const chroma = new Chroma({ red:'196' })
// output will be the custom red chosen
console.log(
chroma.red.paint('Hello world!')
);
Helpful when choosing custom colors.
const chroma = require('chroma-palette')
// output the 256-color palette
console.log(
chroma.palette.paint()
);
FAQs
A light-weight utility for coloring your terminal. 0 dependencies. Default is a preselected color output from the 256 color palette, chosen to enhance legibility.
The npm package chroma-palette receives a total of 4 weekly downloads. As such, chroma-palette popularity was classified as not popular.
We found that chroma-palette demonstrated a not healthy version release cadence and project activity because the last version was released 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.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.