(chore) examples, benchmarks update

pull/3/merge
Amio 2018-07-19 11:19:09 +08:00
rodzic 42c4de58cb
commit b256b23138
2 zmienionych plików z 4 dodań i 4 usunięć

Wyświetl plik

@ -2,14 +2,14 @@ const { Suite } = require('benchmark')
const badgen = require('..')
const longParams = { subject: 'build-build-build', status: 'passing-passing-passing' }
const fullParams = { subject: 'license', status: 'MIT', color: 'cyan' }
const emojiParams = { subject: 'emojis', status: '💩🤱🦄', color: 'cyan' }
const fullParams = { subject: 'license', status: 'Apache 2.0', color: 'cyan' }
const emojiParams = { subject: 'emojis', status: '💩🤱🦄💩🤱🦄', color: 'cyan' }
new Suite()
.add('[classic] style, long params ', () => badgen(longParams))
.add('[classic] style, full params ', () => badgen(fullParams))
.add(' [flat] style, long params ', () => badgen({ style: 'flat', ...longParams }))
.add(' [flat] style, full params ', () => badgen({ style: 'flat', ...fullParams }))
.add('[classic] style, multi bytes ', () => badgen(emojiParams))
.add('[classic] style, emoji params', () => badgen(emojiParams))
.on('cycle', event => console.log(String(event.target)))
.run()

Wyświetl plik

@ -25,7 +25,7 @@ const serveIndex = serveMarked(md, {
title: 'Badgen - Fast badge generator',
preset: 'merri',
inlineCSS: `
body { color: #333 }
body { color: #333; padding-bottom: 5em }
a { text-decoration: none; color: #06D }
a:hover { text-decoration: underline }
table { border-spacing: 0 }