toString (Boolean - JavaScript)
Gets a string representation of the Boolean object.
Defined in
Boolean (Standard - JavaScript)Syntax
toString() : string
Return value | Description |
---|---|
string |
The string representation of the Boolean object. |
Usage
The string representation is eithertrue
or false
.Examples
This computed label displaystrue
or false
depending
on whether height
is greater than width
.var b = new Boolean(sessionScope.height >
sessionScope.width);
b.toString()