function equals(a, b) {
  for (const k in a) {
    if (!(k in b) || a[k] !== b[k]) {
      return false;
    }
  }
  for (const k in b) {
    if (!(k in a)) {
      return false;
    }
  }
  return true;
}
Compares two objects for equality using === on the values.
@param {!Object<K,V>} a
@param {!Object<K,V>} b
@return {boolean}
@template K,V