JavaScript Objects The Boolean Object- toString() - Javascript Objects

What is JavaScript - Boolean toString() Method?

The JavaScript-Boolean toString() method returns a string of either "true" or "false" based upon the value of the object.


Its syntax is shown below −

Return Value:

It returns a string representing the given Boolean object.


Try the below example.


flag.toString is : false

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd Protection Status

Javascript Objects Topics