Skip to content

Commit

Permalink
Example parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
klasjersevi committed May 2, 2019
1 parent e9f766a commit 4271ec3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion helpers/ddata.js
Original file line number Diff line number Diff line change
Expand Up @@ -716,7 +716,7 @@ function parentName (options) {
}

/**
returns a dmd option, e.g. "sort-by", "heading-depth" etc.
returns an option, e.g. "sort-by", "heading-depth" etc.
@static
*/
function option (name, options) {
Expand Down
4 changes: 4 additions & 0 deletions helpers/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -387,6 +387,10 @@ function examples (options) {
if (!(/```/.test(example) || exampleLang === 'off')) {
example = util.format('<pre><code class="%s">%s</code></pre>', exampleLang ? 'language-' + exampleLang : '', example ? example + '\n' : '')
}

if(/```/.test(example)) {
example = ddata.md(example);
}

return prev + options.fn({caption: caption, example: example})
}, '')
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "dbootstrap",
"author": "Weavy",
"version": "4.0.1",
"version": "4.0.2",
"description": "Bootstrap HTML output template for jsdoc2md",
"license": "MIT",
"repository": "https://github.com/Weavy/dbootstrap.git",
Expand Down

0 comments on commit 4271ec3

Please sign in to comment.