hasListener(type) {
    if (!this.listeners_) {
      return false;
    }
    return type
      ? type in this.listeners_
      : Object.keys(this.listeners_).length > 0;
  }
@param {string} [type] Type. If not provided,
    `true` will be returned if this event target has any listeners.
@return {boolean} Has listeners.