It may not be obvious, but JavaScript coercions always result in one of the scalar primitive (seeChapter 2) values, likestring,number, orboolean. There is no coercion that results in a complex value likeobjector
However, suppose they are incompatible with the operation—for example, trying to add a string and a number. In such cases, JavaScript automatically “coerces” one of the types to fit the other to ensure that the operation is successful instead of throwing an error. This process is known a...