- 
                Notifications
    
You must be signed in to change notification settings  - Fork 0
 
negate
        Subhajit Sahu edited this page Jul 29, 2022 
        ·
        2 revisions
      
    Generate a result-negated version of a function.
function negate(x)
// x: a functionconst xfunction = require('extra-function');
var fn = xfunction.negate(isFinite);
fn(Infinity)
// → true
fn(1)
// → false
var fn = xfunction.negate(isNaN);
fn(1);
// → true
fn(NaN);
// → false