Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

yoctocolors

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

yoctocolors - npm Package Compare versions

Comparing version 0.2.0 to 1.0.0

21

package.json
{
"name": "yoctocolors",
"version": "0.2.0",
"description": "The smallest and fastest command-line coloring package on the internet. Trust me.",
"version": "1.0.0",
"description": "The smallest and fastest command-line coloring package on the internet",
"license": "MIT",

@@ -15,4 +15,5 @@ "repository": "sindresorhus/yoctocolors",

"exports": "./index.js",
"types": "./index.d.ts",
"engines": {
"node": "^12.20.0 || ^14.13.1 || >=16.0.0"
"node": ">=14.16"
},

@@ -47,5 +48,13 @@ "scripts": {

"devDependencies": {
"ava": "^3.15.0",
"tsd": "^0.17.0",
"xo": "^0.44.0"
"@jonahsnider/benchmark": "^5.0.0",
"ansi-colors": "^4.1.3",
"ava": "^4.3.0",
"chalk": "^5.0.1",
"cli-color": "^2.0.2",
"colorette": "^2.0.19",
"kleur": "^4.1.5",
"nanocolors": "^0.2.13",
"picocolors": "^1.0.0",
"tsd": "^0.22.0",
"xo": "^0.50.0"
},

@@ -52,0 +61,0 @@ "ava": {

<sup>yoctocolors 🌈</sup>
> The smallest and fastest command-line coloring package on the internet. Trust me.
> The smallest and fastest command-line coloring package on the internet
The only thing that matters is micro-benchmark performance! ⚡️
*Check out [Chalk](https://github.com/chalk/chalk) if you want something more mature and comprehensive.*

@@ -11,7 +9,5 @@

- **4x faster and 5x smaller than [nanocolors](https://github.com/ai/nanocolors)**
- Cat friendly
- An additional color
- Tree-shakeable, not stirred
- Actively maintained (at least for another week)
- 4x faster and 5x smaller than [nanocolors](https://github.com/ai/nanocolors)
- Tree-shakeable
- Actively maintained
- No dependencies

@@ -79,10 +75,20 @@

```sh
$ ./benchmark.js
┌─────────┬────────────────┬─────────────┐
│ (index) │ library │ ops/sec │
├─────────┼────────────────┼─────────────┤
│ 0 │ 'yoctocolors' │ '8,771,930' │
│ 1 │ 'nanocolors' │ '6,896,552' │
│ 2 │ 'colorette' │ '6,172,840' │
│ 3 │ 'picocolors' │ '6,060,606' │
│ 4 │ 'kleur/colors' │ '5,263,158' │
│ 5 │ 'chalk' │ '4,484,305' │
│ 6 │ 'kleur' │ '3,731,343' │
│ 7 │ 'ansi-colors' │ '1,283,697' │
│ 8 │ 'cli-color' │ '393,236' │
└─────────┴────────────────┴─────────────┘
```
❯ ./test/simple-benchmark.js
nanocolors 31508276 ops/sec
picocolors 32524769 ops/sec
yoctocolors 132894792 ops/sec
```
*Benchmark from [`nanocolors`](https://github.com/ai/nanocolors/blob/main/test/simple-benchmark.js)*
*See [benchmark.js](benchmark.js).*

@@ -89,0 +95,0 @@ ## FAQ

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc