Latest
function negate
import { negate } from "https://dotland.deno.dev/x/lodash_es@v0.0.2/src/function.js";

Creates a function that negates the result of the predicate func. The func predicate is invoked with the this binding and arguments of the created function.

Examples

function isEven(n) { return n % 2 == 0; }

_.filter([1, 2, 3, 4, 5, 6], _.negate(isEven)); // => [1, 3, 5]

Parameters

predicate

The predicate to negate.