Skip to main content

Discord Markdown

I needed to render some Discord chat logs as HTML, and found that the Markdown implementation in Discord isn't quite compliant with Common Markdown as Discord uses a simplified version.

So I wrote this library that allows you to convert a discord message written in the Markdown formatting syntax specified here to html.

Installation

You can install the library from pypi:

pip install discord-markdown

Usage

from discord_markdown.discord_markdown import convert_to_html

text = "_This_ **is** an __example__.\nThis should be a different paragraph."
html = convert_to_html(text)

assert html == '<p><i>This</i> <b>is</b> an <u>example</u>.</p><p>This should be a different paragraph.</p>'

Metadata

Release files for discord-markdown 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for discord-markdown 0.4.0
File Size Uploaded Provenance Actions
discord_markdown-0.4.0.tar.gz 4.8 kB Without provenance Details for discord_markdown-0.4.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for discord-markdown 0.4.0
File Interpreter ABI Platform Actions
discord_markdown-0.4.0-py3-none-any.whl Python 3 none any Details for discord_markdown-0.4.0-py3-none-any.whl

Total release size: 11.0 kB

Release files / discord_markdown-0.4.0.tar.gz

Download URL discord_markdown-0.4.0.tar.gz
Size 4.8 kB
Tags Source
SHA-256 checksum
How to use checksums
ce317edf99606e5fe8137c554754f6eb9942caa8526415e5e89bb5afd3292c37
BLAKE2b-256 checksum
How to use checksums
3f8cc05a5a4071a0d08fe2e49673951598c3752fdd248441f5dafe11df64bb08
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.3 CPython/3.6.9 Linux/5.3.0-7642-generic

Release files / discord_markdown-0.4.0-py3-none-any.whl

Download URL discord_markdown-0.4.0-py3-none-any.whl
Size 6.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
94dce3ee4f0f6e889dae26fe8505f9d9ae14872957931da58c368553670f5243
BLAKE2b-256 checksum
How to use checksums
b4f118f2e17aa8ace1930625b9e75c31ebe74dc599c47962719b773bcc2298ee
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.3 CPython/3.6.9 Linux/5.3.0-7642-generic

Security for discord-markdown 0.4.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page