build/component-docs-build.js
function methodsAPIObject(vueObj) {
  const methodsArr = vueObj["methods"] || []
  let methods = []
  
  // construct array of objects for public methods
  methodsArr.forEach((method) => {
    const ele = {
      "name": `${method["name"]}`,
      "parameters": `${method["params"].reduce((paramList, param) => {
          paramList += `${param["name"]}: ${param["type"]["name"]} - ${param["description"]}\n`
          return paramList
      }, '')}`,
      "description": `${method["description"] || 'MISSING DESCRIPTION'}`
    }
    methods.push(ele)
  })
  return methods.length > 0 ? {methods} : null
}
function methodsAPIObject(vueObj) {
  const methodsArr = vueObj["methods"] || []
  let methods = []
  
  // construct array of objects for public methods
  methodsArr.forEach((method) => {
    const ele = {
      "name": `${method["name"]}`,
      "parameters": `${method["params"].reduce((paramList, param) => {
          paramList += `${param["name"]}: ${param["type"]["name"]} - ${param["description"]}\n`
          return paramList
      }, '')}`,
      "description": `${method["description"] || 'MISSING DESCRIPTION'}`
    }
    methods.push(ele)
  })
  return methods.length > 0 ? {methods} : null
}
function methodsAPIObject ( vueObj ) { const methodsArr = vueObj [ "methods" ] || [ ] let methods = [ ] // construct array of objects for public methods methodsArr . forEach ( ( method ) => { const ele = { "name" : ` ${ method [ "name" ] } ` , "parameters" : ` ${ method [ "params" ] . reduce ( ( paramList , param ) => { paramList += ` ${ param [ "name" ] } ${ param [ "type" ] [ "name" ] } ${ param [ "description" ] } \n ` return paramList } , '' ) } ` , "description" : ` ${ method [ "description" ] || 'MISSING DESCRIPTION' } ` } methods . push ( ele ) } ) return methods . length > 0 ? { methods } : null }
Create object representing component public methods
@param {Object} -- JSON object from vue-docgen-api library
@returns {Object} -- Object for component methods that goes into Cedar Data Object
Create object representing component public methods