From 5c579e91a5b3e9f5beb2bf548633a01ba99e0ac9 Mon Sep 17 00:00:00 2001 From: "Sakthipriyan Vairamani (thefourtheye)" Date: Tue, 31 Jan 2017 00:14:59 +0530 Subject: [PATCH] doc: replace newlines in deprecation with space MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As it is, each line in the deprecation heading which are wrapped at 80 characters in the *.md files, are shown in different lines. For example > Stability: 0 - Deprecated: Use > `Buffer.from(arrayBuffer[, byteOffset [, length]])` > instead. is shown in three different lines. This patch replaces the newlines with space characters, so that the output will be in single line. PR-URL: https://github.com/nodejs/node/pull/11074 Reviewed-By: Anna Henningsen Reviewed-By: Jeremiah Senkpiel Reviewed-By: Colin Ihrig Reviewed-By: Timothy Gu Reviewed-By: James M Snell Reviewed-By: Luigi Pinca Reviewed-By: Michaƫl Zasso --- tools/doc/html.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/doc/html.js b/tools/doc/html.js index daa230cb926e4a..b3e5f8d708cc14 100644 --- a/tools/doc/html.js +++ b/tools/doc/html.js @@ -183,7 +183,7 @@ function parseLists(input) { headingIndex = -1; heading = null; } - tok.text = parseAPIHeader(tok.text); + tok.text = parseAPIHeader(tok.text).replace(/\n/g, ' '); output.push({ type: 'html', text: tok.text }); return; } else if (state === 'MAYBE_STABILITY_BQ') {