Boolean (Type)

A native built-in type.

Availability:

ECMAScript edition - 2
Property/method value type:Boolean primitive

Any object or expression that yields a result of type Boolean represents a logical entity.

Logical entities can only represent the true or false states.

These are useful as flags or conditional switches in your script.

See also:Data Type, false, Fundamental data type, true, Type

Cross-references:

ECMA 262 edition 2 - section - 4.3.14

ECMA 262 edition 2 - section - 8.3

ECMA 262 edition 3 - section - 4.3.14

ECMA 262 edition 3 - section - 8.3

O'Reilly JavaScript Definitive Guide - page - 41