src/store/modules/schemas.js
/**
   * Create a new subject with the given Schema
   * @param  {String} options.subject  Subject name
   * @param  {Object} options.schema   Subject schema
   */
Create a new subject with the given Schema
@param  {String} options.subject  Subject name
@param  {Object} options.schema   Subject schema
Create a new subject with the given Schema @param { String } options . subject Subject name @param { Object } options . schema Subject schema
async newSubject ({dispatch}, {subject, schema}) {
    schema = JSON.stringify(schema)
    await clusters.request(CLUSTER_SCHEMA_REGISTRY, {
      accept: SCHEMA_CONTENT_JSON
    }).post(`/subjects/${subject}`, {
      schema
    })
    await dispatch('fetchAvailable')
  }
async newSubject ( { dispatch } , { subject , schema } ) { schema = JSON . stringify ( schema ) await clusters . request ( CLUSTER_SCHEMA_REGISTRY , { accept : SCHEMA_CONTENT_JSON } ) . post ( ` ${ subject } ` , { schema } ) await dispatch ( 'fetchAvailable' ) }
Create a new subject with the given Schema
 @param  {String} options.subject  Subject name
 @param  {Object} options.schema   Subject schema
Create a new subject with the given Schema @param { String } options . subject Subject name @param { Object } options . schema Subject schema