Navigation Menu

Skip to content

niebert/jsoneditor_app

Repository files navigation

AppLSAC jsoneditor_app

This is a Demo for an AppLSAC with the

Preview of WebApp

Title Demo URL for Demo
Default Demo JSON Editor https://niebert.github.io/jsoneditor_app
Default Demo with Menu https://niebert.github.io/jsoneditor_app/index4menu.html

The second demo was create with JSON2Schema and JSONEditor4Menu.

Applications in other Repositories

  • JSON2Schema on GitLab uses the jsoneditor_app as AppLSAC and replaces the default JSON schema in schema/schema4json.js by a generated new schema created by JSON2Schema. JSON2Schema uses jsoneditor_app as default AppLSAC and creates a JSON schema from a given JSON and the JSON schema is used for the definition of the input elements for this JSON editor jsoneditor_app. So JSON2Schema replaces the schema in file jsoneditor_app/schema/schema4json.js in the jsoneditor_app.zip with a dynamically generated JSON Schema and provides the updated jsoneditor_app.zip for download in JSON2Schema on GitLab.

Validation of the ZIP jsoneditor_app.zip in JSON2Schema

JSON2Schema is an AppLSAC just like jsoneditor_app. It runs offline and does not require internet resources other than the browser. Nevertheless a ZIP can be used to ship harmful code to the client. Therefore it is important that the content of the generated ZIP-file can be assessed by the user of JSON2Schema. This repository jsoneditor_app shows the content of the ZIP-file. The ZIP-file can be base64 encoded with create_files4json.html and the ZIP-file for the jsoneditor_app repository can be stored in as JSON data for further processing in an AppLSAC like JSON2Schema.

JSON2Schema adds a new JSON schema and Handlebars4Code template according to the input JSON to the jsoneditor_app.zip.

Furthermore if you want to replace this JSON editor by your own JSON editor e.g. with a different layout or a new release of the JSON Editor json-editor, please feel free to encode your own modified ZIP file of your JSON Editor jsoneditor_app by create_files4json.html into a base64 encoded library that stores your ZIP for further processing just in your browser as AppLSAC. With create_files4json.html you can replace your own JSON editor by default JSON Editor in db/files4json.js of JSON2Schema with your own jsoneditor_app. It is recommended to use a JSON editor of Jeremy Dorn so that the JSON schema is support for the editor. For the underlying jsoneditor by Jeremy Dorn it might be necessary to generate an adapted version of schema4json.js that matches with the schema definition of your own JSON editor. The generated schema is delivered in schema/schema4json.js. If you want alter the underlying JSON replace the following:

  • tpl/template4json_tpl.js that contains the template for rendering the output with Handlebars4Code.
  • schema/schema4json.js that defines the JSON Schema for definition of input elements in the JSON editor according to the JSON elements.

About

JSON Editor by Jeremy Dorn extended with LoadFile4DOM and FIleSaver by Eli Grey

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages