Skip to content

Commit

Permalink
fix(lib/markdownbuilder.js): propTable property anchor link generated…
Browse files Browse the repository at this point in the history
… with github-slugger
  • Loading branch information
ferran-gali-lifullconnect committed Oct 20, 2020
1 parent fd88b0b commit 9883b8f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/markdownBuilder.js
Original file line number Diff line number Diff line change
Expand Up @@ -309,9 +309,9 @@ function build({
* Generates the overview table row for a single property definition
* @param {*} param0
*/
function makepropheader(required = [], ispattern = false) {
function makepropheader(required = [], ispattern = false, slugger) {
return ([name, definition]) => tableRow([
tableCell(ispattern ? inlineCode(name) : link(`#${name}`, '', text(name))), // Property
tableCell(ispattern ? inlineCode(name) : link(`#${slugger.slug(name)}`, '', text(name))), // Property
tableCell(type(definition)),
tableCell(text(required.indexOf(name) > -1 ? i18n`Required` : i18n`Optional`)),
tableCell(nullable(definition)),
Expand Down

0 comments on commit 9883b8f

Please sign in to comment.