Skip to main content

YAML metadata extension for Python-Markdown

Project description

YAML metadata extension for Python-Markdown

Build Status Coverage Status Code style: black Python versions PyPi

This extension adds YAML meta data handling to markdown with all YAML features.

As in the original, metadata is parsed but not used in processing.

Metadata parsed as is by PyYaml and without additional transformations, so this plugin is not compatible with original Meta-Data extension.

Basic Usage

import markdown


text = """---
title: What is Lorem Ipsum?
categories:
  - Lorem Ipsum
  - Stupid content
...

Lorem Ipsum is simply dummy text.
"""

md = markdown.Markdown(extensions = ['full_yaml_metadata'])
md.convert(text) == '<p>Lorem Ipsum is simply dummy text.</p>'
md.Meta == {'title': 'What is Lorem Ipsum?', 'categories': ['Lorem Ipsum', 'Stupid content']}

Development and contribution

  • install project dependencies
python setup.py develop
  • install linting, formatting and testing tools
pip install -r requirements.txt
  • run tests
pytest
  • run linters
flake8
black --check ./
  • feel free to contribute!

Python versions compatibility

This plugin tested with python versions 3.6 and 3.7.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

markdown-full-yaml-metadata-2.0.2.tar.gz (4.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

markdown_full_yaml_metadata-2.0.2-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file markdown-full-yaml-metadata-2.0.2.tar.gz.

File metadata

  • Download URL: markdown-full-yaml-metadata-2.0.2.tar.gz
  • Upload date:
  • Size: 4.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.6

File hashes

Hashes for markdown-full-yaml-metadata-2.0.2.tar.gz
Algorithm Hash digest
SHA256 692143dc1454d393fcb80d367404f5914a717b9f3635d72c4a013e7e3f784d27
MD5 55a5a897e724dd9c0806ce35b0349b35
BLAKE2b-256 e783944f791a578a8441320387dccb80be13b698293ebebbfad086029c5175a0

See more details on using hashes here.

File details

Details for the file markdown_full_yaml_metadata-2.0.2-py3-none-any.whl.

File metadata

  • Download URL: markdown_full_yaml_metadata-2.0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.6

File hashes

Hashes for markdown_full_yaml_metadata-2.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 04d6ec6861c8334e9c2316956ccbda0b300dae5f48b86517c6264f7e989ef93e
MD5 da2e3f98e7385586c9eb3d58cc58a1e7
BLAKE2b-256 fc35c7e53ea4e3e503e00d383ac5f6d1651ee90a83da73cf7f64e2851d3acd3e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page