Convert a Boolean value to a string:
var x = bool.toString();
The result of x will be:
Try it yourself »
Definition and Usage
The toString() method returns a boolean value as a string.
The toString() method is supported in all major browsers.
|String||Either "true" or "false"|
Thank You For Helping Us!
Your message has been sent to W3Schools.