Skip to main content

Python module for clean, human-readable printing of data structures.

Project description

prettierprint

Python module for clean, human-readable printing of data structures.

Quickstart

Install

pip install prettierprint

Usage

Basic:

from prettierprint import print

some_data = {'key': 'value', 'list': [{'name': 'Hello', 'attr_A': 'foo', 'attr_B': 'bar'}, {'name': 'World', 'attr_A': 'bar', 'attr_B': 'foo'}]}

print(some_data)

Result:

key: value
list:
    - name: Hello
      attr_A: foo
      attr_B: bar
    - name: World
      attr_A: bar
      attr_B: foo

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

prettierprint-1.1.2.tar.gz (3.4 kB view hashes)

Uploaded Source

Built Distribution

prettierprint-1.1.2-py3-none-any.whl (4.2 kB view hashes)

Uploaded Python 3

Supported by

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