@xops.net/json-schema-to-react-tree

json-schema to react material-ui tree

Usage no npm install needed!

<script type="module">
  import xopsNetJsonSchemaToReactTree from 'https://cdn.skypack.dev/@xops.net/json-schema-to-react-tree';
</script>

README

json-schema-to-react-tree

A react component to visually display JSON Schemas

image

Usage

npm install @xops.net/json-schema-to-react-tree

import React from "react";
import JSONSchemaTree from "@xops.net/json-schema-to-react-tree";

const MyApp = (props) => {
  return (
    <>
      <JSONSchemaTree
        schema={{
          type: "object",
          properties: {
            number: {
              type: "string",
            },
            hash: {
              type: "string",
            },
            timestamp: {
              description: "timestamp in which the block occured",
              title: "Timestamp",
              type: "string",
            },
            transactions: {
              type: "string",
            },
          },
        }} />
    </>
  )
}
export default MyApp;

Contributing

How to contribute, build and release are outlined in CONTRIBUTING.md, BUILDING.md and RELEASING.md respectively. Commits in this repository follow the CONVENTIONAL_COMMITS.md specification.