Reduce function that returns true if any of the values are truthy.
let vals = [ 0, null, undefined ];vals.reduce(anyTrueR, true); // falsevals.push("hello world");vals.reduce(anyTrueR, true); // true Copy
let vals = [ 0, null, undefined ];vals.reduce(anyTrueR, true); // falsevals.push("hello world");vals.reduce(anyTrueR, true); // true
Reduce function that returns true if any of the values are truthy.
Example