Thibault Derousseaux 9be3a439ca fixup! Update react and react-dom to let extensions use React hooks 6 年之前
..
src aec80eca18 Clean up json-extension 6 年之前
style 0bed288d4c Use InputGroup in json-extension 6 年之前
README.md 049fc2ab07 Lint fixes 6 年之前
package.json 9be3a439ca fixup! Update react and react-dom to let extensions use React hooks 6 年之前
tdoptions.json 5fee8c5389 Switch to ts 3.1 6 年之前
tsconfig.json a930534bbf Use InputGroup in json-extension 6 年之前

README.md

json-extension

A JupyterLab extension for rendering JSON as a tree

demo

Prerequisites

  • JupyterLab ^0.27.0

Usage

To render JSON-able dict or list in IPython:

from IPython.display import JSON

JSON({
    "string": "string",
    "array": [1, 2, 3],
    "bool": True,
    "object": {
        "foo": "bar"
    }
})

To render a fully expanded tree:

JSON({
    "string": "string",
    "array": [1, 2, 3],
    "bool": True,
    "object": {
        "foo": "bar"
    }
}, expanded=True)

To render a .json file, simply open it:

Development

See the JupyterLab Contributor Documentation.