{"library":"mdit-plain","title":"mdit-plain","description":"mdit-plain is a Python renderer for the markdown-it-py library, designed to convert Markdown documents into clean plain text by effectively stripping out all markup. Its primary purpose is to facilitate Natural Language Processing (NLP) and other text-based analyses where unformatted content is required. The current version is 1.0.1, released in January 2023, indicating a slow release cadence since then.","language":"python","status":"active","last_verified":"Thu Apr 16","install":{"commands":["pip install mdit-plain"],"cli":null},"imports":["from mdit_plain.renderer import RendererPlain","from markdown_it import MarkdownIt"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"from markdown_it import MarkdownIt\nfrom mdit_plain.renderer import RendererPlain\n\nmarkdown_text = \"\"\"\n# Header One\n\nThis is **some** *markdown* text with a [link](https://example.com).\n\n* List item 1\n* List item 2\n\n> A blockquote.\n\"\"\"\n\n# Initialize MarkdownIt parser with the plain text renderer\nparser = MarkdownIt(renderer_cls=RendererPlain)\n\n# Render the markdown to plain text\nplain_text = parser.render(markdown_text)\n\nprint(plain_text)\n# Expected Output:\n# Header One\n#\n# This is some markdown text with a link.\n#\n# * List item 1\n# * List item 2\n#\n# > A blockquote.","lang":"python","description":"This quickstart demonstrates how to initialize markdown-it-py with the mdit-plain renderer to convert a Markdown string into plain text, effectively removing all formatting.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}