-
-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Labels
Description
After inspecting the code, it seems there is an undocumented feature: markedRenderer. See this gist for more info. It would be nice to add that to README.md so people can know about this shortcut :).
Also, at first it wasn't clear to me that I had to put markedOptions in docpadConfig.plugins.marked. (I tried things like docpadConfig.plugins.markedOptions and docpadConfig.plugins.marked.[marked setting here]. This was probably due to me not interpreting correctly, but some extra clarity never hurts.
I suggest something like this snippet:
You can customise the Marked options by using the `markedOptions` object. Custom marked renderers can be added via `markedRenderer`, like so:
docpadConfig =
plugins:
marked:
markedOptions:
# customize Marked here... (see https://github.com/chjj/marked#options-1)
markedRenderer:
# custom renderer methods here...
# same as passing a custom renderer instance to `docpadConfig.plugins.marked.markedOptions.renderer` (https://github.com/chjj/marked#renderer)
# for accepted keys, refer: https://github.com/chjj/marked#block-level-renderer-methods and https://github.com/chjj/marked#inline-level-renderer-methods
javaguy