The void operator is use to prevent an expression from returning a value.
Syntax
void expression
The expression argument is any valid JavaScript expression.
Example
The void operator evaluates its expression, and returns undefined. It is most useful in situations where you want an expression evaluated but do not want the results visible to the remainder of the script.
See also: Operator Behavior, Operator Precedence, Operator Summary |