This is a development version (latest) and may be unstable.Go to latest (9.17.0)
{ } Raw JSON

bundles / IPython latest / IPython / core / formatters / JSONFormatter

MetaHasTraits

IPython.core.formatters:JSONFormatter

source: /IPython/core/formatters.py:875

Signature

def JSONFormatter(**kwargs: t.Any) → None

Members

Summary

A JSON string formatter.

Extended Summary

To define the callables that compute the JSONable representation of your objects, define a _repr_json_ method or use the for_type or for_type_by_name methods to register functions that handle this.

The return value of this formatter should be a JSONable list or dict. JSON scalars (None, number, string) are not allowed, only dict or list containers.

Aliases

  • IPython.core.formatters.JSONFormatter