From cf0b3e3212d27759d5857e09848979f31bc8ea1c Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Sun, 31 Jul 2016 22:16:11 -0700 Subject: [PATCH] Update docdown options. --- lib/main/build-doc.js | 23 +++++++++++++++-------- lib/main/build-site.js | 3 --- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/lib/main/build-doc.js b/lib/main/build-doc.js index 95dca8eef..f52b87bb2 100644 --- a/lib/main/build-doc.js +++ b/lib/main/build-doc.js @@ -16,22 +16,29 @@ var pkg = require('../../package.json'), var config = { 'base': { - 'entryLinks': [ - '<% if (name == "templateSettings" || !/^(?:methods|properties|seq)$/i.test(category)) {' + - 'print("[npm package](https://www.npmjs.com/package/lodash." + name.toLowerCase() + ")")' + - '} %>' - ], 'path': path.join(basePath, 'lodash.js'), - 'sourceLink': '[source](${sourceHref})', 'title': 'lodash v' + version + '', 'toc': 'categories', 'url': 'https://github.com/lodash/lodash/blob/' + version + '/lodash.js' }, 'github': { - 'hash': 'github' + 'style': 'github', + 'sublinks': [ + '<% if (name == "templateSettings" || !/^(?:methods|properties|seq)$/i.test(category)) {' + + 'print("[Ⓝ](https://www.npmjs.com/package/lodash." + name.toLowerCase() + " \\"See the npm package\\")")' + + '} %>' + ] }, 'site': { - 'tocHref': '#docs' + 'entryLink': '', + 'sourceLink': '[source](${sourceHref})', + 'tocHref': '', + 'tocLink': '', + 'sublinks': [ + '<% if (name == "templateSettings" || !/^(?:methods|properties|seq)$/i.test(category)) {' + + 'print("[npm package](https://www.npmjs.com/package/lodash." + name.toLowerCase() + ")")' + + '} %>' + ] } }; diff --git a/lib/main/build-site.js b/lib/main/build-site.js index 70d524bba..88298db07 100644 --- a/lib/main/build-site.js +++ b/lib/main/build-site.js @@ -23,9 +23,6 @@ function build(type) { // Remove docdown horizontal rules. $('hr').remove(); - // Remove table of contents (toc) links. - $('a[href="#docs"]').remove(); - // Remove marky-markdown additions. $('[id^="user-content-"]') .attr('class', null)