Compares numeric values - numbers, bigints and numeric strings - by exact numeric value,
whatever their type or spelling: 1 == '1' == 1n == '1.0' == '1e0', '2' < '10', and
integers beyond double precision compare exactly ('9007199254740993' > 9007199254740992).
Singleton values follow NaN < -Infinity < finite numbers < Infinity ordering.
Non-numeric strings sort with NaN: after it, in lexicographic order among themselves.
NaN is considered equal to itself.
-0 is considered equal to 0.
Compares numeric values - numbers, bigints and numeric strings - by exact numeric value, whatever their type or spelling:
1 == '1' == 1n == '1.0' == '1e0','2' < '10', and integers beyond double precision compare exactly ('9007199254740993' > 9007199254740992). Singleton values followNaN < -Infinity < finite numbers < Infinityordering. Non-numeric strings sort withNaN: after it, in lexicographic order among themselves. NaN is considered equal to itself. -0 is considered equal to 0.