code: function getPathFromContext (ctx) {
    let path = ctx.path.join('.')
  
    // check if we specifically set type
    const lastElement = ctx.path[ctx.path.length - 1]
    if (lastElement) {
      const lev = lastElement.toLowerCase()
      if (lev === 'type') {
        path = ctx.path.slice(0, ctx.path.length - 1).join('.')
      }
    }
  
    // check if in array
    const reg = new RegExp('^\\d+$')
    const lastPath = path.substring(path.lastIndexOf('.') + 1)
    if (lastPath && reg.test(lastPath)) {
      path = path.substring(0, path.lastIndexOf('.'))
    }
  
    return path
  }
docs: /*!
  @param ctx
  @returns {string}