Files
30-seconds-of-code/node_modules/remark-stringify/lib/visitors/blockquote.js
2019-08-20 15:52:05 +02:00

19 lines
345 B
JavaScript

'use strict';
module.exports = blockquote;
function blockquote(node) {
var values = this.block(node).split('\n');
var result = [];
var length = values.length;
var index = -1;
var value;
while (++index < length) {
value = values[index];
result[index] = (value ? ' ' : '') + value;
}
return '>' + result.join('\n>');
}