diff --git a/tools/doc/tools/toc.js b/tools/doc/tools/toc.js index aa891e47b0c..e626fd61caf 100644 --- a/tools/doc/tools/toc.js +++ b/tools/doc/tools/toc.js @@ -2,7 +2,7 @@ const path = require('path'); const fs = require('fs'); const remark = require('remark'); const replaceSection = require('mdast-util-heading-range'); -const { toString } = require('mdast-util-to-string'); +const toString = require('mdast-util-to-string'); const ejs = require('ejs'); const unist = require('../unistHelpers'); const mdNav = require('../mdNav'); diff --git a/tools/doc/unistHelpers.js b/tools/doc/unistHelpers.js index bfc75155a0d..0b332a980ac 100644 --- a/tools/doc/unistHelpers.js +++ b/tools/doc/unistHelpers.js @@ -60,6 +60,12 @@ module.exports = { children: content }; }, + makeInlineCode: function (codeText) { + return { + "type": "inlineCode", + "value": codeText + } + }, makeImage: function (url, alt) { return { type: 'image',