if
Conditional branching for Javascript
Installation
npm install if
Usage
If the condition is truthy, the handler function passed to Then
will be called.
;
A handler can be passed to the Else
method, which will be called if the condition is not truthy.
;
To evaluate more conditions, call If
after Else
.
;
Example
;