code: function isEquivalentType(typeA: GraphQLType, typeB: GraphQLType): boolean {
    // Easy short-circuit: equal types are equal.
    if (typeA === typeB) {
      return true;
    }
  
    // If either type is non-null, the other must also be non-null.
    if (typeA instanceof GraphQLNonNull && typeB instanceof GraphQLNonNull) {
      return isEquivalentType(typeA.ofType, typeB.ofType);
    }
  
    // If either type is a list, the other must also be a list.
    if (typeA instanceof GraphQLList && typeB instanceof GraphQLList) {
      return isEquivalentType(typeA.ofType, typeB.ofType);
    }
  
    // Make sure the two types are of the same class
    if (typeA.constructor.name === typeB.constructor.name) {
      const rawA = getRawType(typeA);
      const rawB = getRawType(typeB);
  
      // And they must have the exact same name
      return rawA.name === rawB.name;
    }
  
    // Otherwise the types are not equal.
    return false;
  }
docs: Determine if a type is the same type (same name and class) as another type.
  Needed if we're comparing IRs created at different times: we don't yet have
  an IR schema, so the type we assign to an IR field could be !== than
  what we assign to it after adding some schema definitions or extensions.