spaceout/front_end/node_modules/command-line-usage/lib/chalk-format.js
2020-12-12 10:25:30 -05:00

12 lines
227 B
JavaScript

function chalkFormat (str) {
if (str) {
str = str.replace(/`/g, '\\`')
const chalk = require('chalk')
return chalk(Object.assign([], { raw: [ str ] }))
} else {
return ''
}
}
module.exports = chalkFormat