code: function namespaceType (ns /* : string */) /* : string */ {
    const parts = ns.split(':')
    if (parts.length < 2) {
      return ''
    }
    return parts.slice(0, -1).join(':')
  }
docs: The first component of a namespace. `foo` in `foo:bar`
  
  @param {string} ns
  @returns {string}