function-noop

    0.1.2 • Public • Published

    function-noop

    NPM

    Do nothing and get undefined, like _.noop.

    const noop = require('function-noop');
    // noop()
     
    noop(1, 2);
    // undefined
    [1, 2].map(noop);
    // [undefined, undefined]
    new Promise((fres, frej) => frej()).then(() => console.log('ok'), noop);
    // (promise rejection caught)

    Install

    npm i function-noop

    DownloadsWeekly Downloads

    0

    Version

    0.1.2

    License

    MIT

    Last publish

    Collaborators

    • wolfram77