This might be a very silly question, but can I rely on the toString() function regardless of the language settings of a client?
That is, for me:
x = true;
x.toString(); // "true"
If someone from France ran my application, would the output be "true" or "vrai"?
For booleans, a conforming ECMAScript interpreter must convert true to "true" and false to "false" (§9.8 and §15.6.4.2).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With