Skip to content

Is there a way for a renderer to defer to the default behavior? #3659

Answered by calculuschild
rschristian asked this question in Q&A

You must be logged in to vote

Keep reading to the next paragraph:

Calling marked.use() to override the same function multiple times will give priority to the version that was assigned last. Overriding functions can return false to fall back to the previous override in the sequence, or resume default behavior if all overrides return false.

Just have your custom renderer return false at the point you want it to fall back to default behavior.

If this isn't clear, let us know how we can improve the wording.

Replies: 1 comment 2 replies

You must be logged in to vote
2 replies
@rschristian

@calculuschild

Answer selected by rschristian
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants