mirror of
https://github.com/JuanCanham/HackMyResume.git
synced 2025-05-10 15:57:07 +01:00
Gather.
This commit is contained in:
18
src/utils/md2chalk.js
Normal file
18
src/utils/md2chalk.js
Normal file
@ -0,0 +1,18 @@
|
||||
/**
|
||||
Inline Markdown-to-Chalk conversion routines.
|
||||
@license MIT. See LICENSE.md for details.
|
||||
@module md2chalk.js
|
||||
*/
|
||||
|
||||
(function(){
|
||||
|
||||
var MD = require('marked');
|
||||
var CHALK = require('chalk');
|
||||
var LO = require('lodash');
|
||||
|
||||
module.exports = function( v, style ) {
|
||||
var temp = v.replace(/\*\*(.*?)\*\*/g, CHALK.bold('$1'));
|
||||
return style ? LO.get(CHALK, style)(temp) : temp;
|
||||
};
|
||||
|
||||
}());
|
Reference in New Issue
Block a user