xtal-json-editor

WebJar for xtal-json-editor

License

License

MIT
Categories

Categories

JSON Data
GroupId

GroupId

org.webjars.bowergithub.bahrus
ArtifactId

ArtifactId

xtal-json-editor
Last Version

Last Version

0.0.12
Release Date

Release Date

Type

Type

jar
Description

Description

xtal-json-editor
WebJar for xtal-json-editor
Project URL

Project URL

http://webjars.org
Source Code Management

Source Code Management

https://github.com/bahrus/xtal-json-editor

Download xtal-json-editor

How to add to project

<!-- https://jarcasting.com/artifacts/org.webjars.bowergithub.bahrus/xtal-json-editor/ -->
<dependency>
    <groupId>org.webjars.bowergithub.bahrus</groupId>
    <artifactId>xtal-json-editor</artifactId>
    <version>0.0.12</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.bowergithub.bahrus/xtal-json-editor/
implementation 'org.webjars.bowergithub.bahrus:xtal-json-editor:0.0.12'
// https://jarcasting.com/artifacts/org.webjars.bowergithub.bahrus/xtal-json-editor/
implementation ("org.webjars.bowergithub.bahrus:xtal-json-editor:0.0.12")
'org.webjars.bowergithub.bahrus:xtal-json-editor:jar:0.0.12'
<dependency org="org.webjars.bowergithub.bahrus" name="xtal-json-editor" rev="0.0.12">
  <artifact name="xtal-json-editor" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.bowergithub.bahrus', module='xtal-json-editor', version='0.0.12')
)
libraryDependencies += "org.webjars.bowergithub.bahrus" % "xtal-json-editor" % "0.0.12"
[org.webjars.bowergithub.bahrus/xtal-json-editor "0.0.12"]

Dependencies

compile (2)

Group / Artifact Type Version
org.webjars.bowergithub.polymer : polymer jar [2.0.0,3)
org.webjars.bowergithub.bahrus : json-merge jar [0.1.0,0.2)

Project Modules

There are no modules declared in this project.

Published on webcomponents.org

<xtal-json-editor>

Vanilla web component wrapper around josdejong's awesome, most excellent JSON Editor api, which can be found at https://github.com/josdejong/jsoneditor

Although the web component does not depend on Polymer, it can work with its binding. The output of the editor can either be text, or JSON, as specified by the as attribute:

    <div>Input:</div>
    <xtal-json-editor id="firstEditor" options="{}" as="json"></xtal-json-editor>
    <p-d on="edited-result-changed" to="xtal-json-editor{input}"></p-d>
    <div>Output:</div>
    <xtal-json-editor options="{}"></xtal-json-editor>

The markup above is using the pass down element (p-d) to bind the two instances together, but you can also use Polymer or custom event handling.

Viewing Your Element

$ npm install
$ npm run serve

or

<script type=module src="https://cdn.pika.dev/xtal-json-editor"></script>

Versions

Version
0.0.12
0.0.6