badgen/README.md

1.7 KiB
Czysty Wina Historia

badgen npm-version install size

Fast, handcraft, pure JavaScript badge generator.

Usage

npm package

npm install badgen

const badgen = require('badgen')

const svgString = badgen({
  subject: 'npm',   // <Text>
  status: 'v1.2.3', // <Text>
  color: 'blue'     // <Color RGB> or <Color Name>
})

Available color names:

Badge Service

https://badgen.now.sh/

Benchmarks

npm run bench on my iMac5K(Late 2014), 3.5G i5, with Node.js 10.5.0:

generate by short params x 543,857 ops/sec ±0.98% (90 runs sampled)
generate by long params  x 512,747 ops/sec ±0.66% (91 runs sampled)
generate by full params  x 461,409 ops/sec ±0.78% (90 runs sampled)

License

ISC