markdown-it / markdown-it-footnote

Footnotes plugin for markdown-it markdown parser
https://markdown-it.github.io/
MIT License
212 stars 59 forks source link

Option to disable footnotes rendering #18

Closed bridgeport closed 7 years ago

bridgeport commented 7 years ago

Thanks for providing this great plugin. I have a project with many markdown files containing many footnotes. For some of them I need to disable the rendering of footnotes entirely without removing the actual footnote code from the markdown files. So, it would strip footnotes output.

Would you be open to adding an enabled/disabled option that could be passed to the plugin?

Thanks.

puzrin commented 7 years ago

I prefer avoid new options if problem can be solved without those. That helps to keep api clear. In your case you can replace footnote renderer functions with dummy ones. Create 2 configured markdown instances (one with modified footnote), and select needed for each file.

bridgeport commented 7 years ago

Thanks for the suggestion @puzrin