MDN URL
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Addition#addition_using_bigints
What specific section or headline is this issue about?
Addition using BigInts
What information was incorrect, unhelpful, or incomplete?
Strings take priority over BigInts as described in the "Description" part of the page, hence it's valid and doesn't throw a TypeError at runtime.
What did you expect to see?
"1" + 2n doesn't throw a TypeError, so it shouldn't be there or should be replaced with a proper invalid example.
Do you have any supporting links, references, or citations?
In the same page. console.log("1" + 2n) also runs in the playground.
Do you have anything more you want to share?
No response
MDN metadata
Page report details
MDN URL
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Addition#addition_using_bigints
What specific section or headline is this issue about?
Addition using BigInts
What information was incorrect, unhelpful, or incomplete?
Strings take priority overBigInts as described in the "Description" part of the page, hence it's valid and doesn't throw aTypeErrorat runtime.What did you expect to see?
"1" + 2ndoesn't throw aTypeError, so it shouldn't be there or should be replaced with a proper invalid example.Do you have any supporting links, references, or citations?
In the same page.
console.log("1" + 2n)also runs in the playground.Do you have anything more you want to share?
No response
MDN metadata
Page report details
en-us/web/javascript/reference/operators/addition