json-schema-editor-react16

0.2.30 • Public • Published

JSON Schema Editor

npm badge

Generates HTML for creating and modifying json schemas. I created this because json-editor is not good at modifying schemas (using the meta schema) and couldn't find any other good UI for making json schemas.

Getting started


  1. Make sure React is loaded on your page. Read more at facebook/react.

  2. Include JSON Schema Editor

  • Using npm:
npm install json-schema-editor
import JSONSchemaEditor from 'json-schema-editor';
  1. Initialize the component
render() {
  return (
    <JSONSchemaEditor
      data={{}}
      onChange={console.log}
    />
  );
}

Example


Here is what the product schema example looks like rendered.

JSON Schema Editor Example

Todo

  • Add support for the description field.
  • exclusiveMinimum and exclusiveMaximum, are these even necessary?
  • refs
  • definitions
  • patternProperties
  • allOf, anyOf, oneOf

Readme

Keywords

none

Package Sidebar

Install

npm i json-schema-editor-react16

Weekly Downloads

2

Version

0.2.30

License

MIT

Last publish

Collaborators

  • zadkiel