From ccc37ce2b3bc8620a097b7fcc1eacd696b328a3d Mon Sep 17 00:00:00 2001 From: Lu Nelson Date: Fri, 8 Feb 2019 14:04:14 +0100 Subject: [PATCH] add trim() inside markdownFIle function --- lib/functions-pug.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/functions-pug.js b/lib/functions-pug.js index deeac5a..c09f2b3 100644 --- a/lib/functions-pug.js +++ b/lib/functions-pug.js @@ -118,7 +118,7 @@ module.exports = function (srcDir, pubDir, options) { content } = grayMatter(fs.readFileSync(absFile, 'utf8')); depFiles.push(absFile); - return '\n' + mdi.render(content).trim(); + return '\n' + mdi.render(content.trim()).trim(); }, writeFile(relFile, content) { const absFile = srcResolve(relFile);