node-cli-colors-benchmark

Benchmarking node:util#styleText, ansi-colors, ansis, chalk, colorette, picocolors

Stars
1

color-perf

Run it

  1. Install node 21.7+
  2. pnpm install
  3. pnpm run bench

Results

Ran on a basic GH Actions runner.

Lower is better. Leftmost is the base, with the others being the difference from the base.

xychart-beta
  title "src/main.bench.ts > one (red)"
  x-axis ["[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "node:[email protected]"]
  y-axis Difference from fastest
  bar [1.0000, 1.2242, 3.0563, 3.1742, 6.0268, 9.8374]
xychart-beta
  title "src/main.bench.ts > two (red, bold)"
  x-axis ["[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "node:[email protected]"]
  y-axis Difference from fastest
  bar [1.0000, 1.1589, 3.0600, 4.0125, 9.2253, 13.6032]
xychart-beta
  title "src/main.bench.ts > three (blue, bold, italic)"
  x-axis ["[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "node:[email protected]"]
  y-axis Difference from fastest
  bar [1.0000, 1.8920, 2.5667, 5.5117, 13.7788, 18.8354]
xychart-beta
  title "src/main.bench.ts > complex"
  x-axis ["[email protected]", "[email protected]", "[email protected]", "[email protected]", "node:[email protected]", "[email protected]"]
  y-axis Difference from fastest
  bar [1.0000, 3.9825, 8.5197, 18.4464, 40.7668, 46.0673]