Metadata-Version: 2.4
Name: md-to-text-lite
Version: 0.1.0
Summary: A zero-dependency Python micro-tool to quickly convert Markdown strings into clean, readable plain text.
Author-email: Encephos <magiltraun@gmail.com>
Project-URL: Homepage, https://github.com/Encephos/md-to-text-lite
Keywords: markdown,text,converter,plain-text,strip,zero-dependency
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Intended Audience :: Developers
Classifier: Topic :: Text Processing :: Markup :: Markdown
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Dynamic: license-file

# md-to-text-lite 

[![PyPI version](https://img.shields.io/pypi/v/md-to-text-lite.svg)](https://pypi.org/project/md-to-text-lite/)
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)

A zero-dependency Python micro-tool to strip Markdown formatting and extract clean, readable plain text.

## The Problem
When you scrape websites, process LLM outputs, or prepare documents for Text-to-Speech (TTS), you often end up with Markdown strings full of `**bold**`, `[links](url)`, and `# Headers`. You just want the plain text, but importing heavy HTML/Markdown parsers like `beautifulsoup4` or `markdown` just to strip text is overkill.

## The Solution
`md-to-text-lite` uses pure standard library regex to intelligently strip markdown syntax while preserving the actual content. It runs in microseconds.

## Installation
```bash
pip install md-to-text-lite
```

## Usage

```python
from md_to_text_lite import markdown_to_text

md_string = """
# Hello World
This is a **bold** statement with a [link](https://github.com).
* List item 1
* List item 2
"""

clean_text = markdown_to_text(md_string)
print(clean_text)

# Output:
# Hello World
# This is a bold statement with a link.
# List item 1
# List item 2
```

## Features
* **Zero Dependencies:** Pure Python standard library (`re`).
* **Intelligent Stripping:** Keeps the alt-text of images and text of links, removes URLs.
* **Code Blocks:** Removes multi-line code blocks entirely (since you usually don't want to read code aloud or count it in word metrics).
```
