Skip to content

Commit

Permalink
Merge pull request markedjs#1 from szego/disable-elements
Browse files Browse the repository at this point in the history
Disable elements in InlineLexer as well
  • Loading branch information
Guichaguri committed Dec 1, 2015
2 parents 87df6f3 + a3fe3b9 commit f62674c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/marked.js
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,10 @@ function InlineLexer(links, options) {
} else if (this.options.pedantic) {
this.rules = inline.pedantic;
}

for(var i = 0; i < this.options.disabledElements.length; i++) {
this.rules[this.options.disabledElements[i]] = noop;
}
}

/**
Expand Down

0 comments on commit f62674c

Please sign in to comment.