# Json editor

This article uses a third-party Json editor v-jsoneditor

# Effect

v-jsoneditor

# Installation

Node

npm install v-jsoneditor

Browser

<script src="https://unpkg.com/v-jsoneditor/docs/dist/v-jsoneditor.min.js"></script>

# Import

Node

import VJsoneditor from 'v-jsoneditor'

Browser

var VJsoneditor = window.VJsoneditor.default;

# Mounting

Vue.use(VJsoneditor);
//or
Vue.component('VJsoneditor', VJsoneditor);
//or
formCreate.component('VJsoneditor', VJsoneditor);

# Generate

$f = formCreate.create([
     {
         type: 'v-jsoneditor',
         title: 'json',
         field: 'json',
         value:{
             type: 'form-create'
         }
     }
])

# Modify

$f.setValue('json', {type: 'form-create v2'})