Have ideas to improve npm?Join in the discussion! »

    set-immediate-shim

    2.0.0 • Public • Published

    set-immediate-shim Build Status

    Simple setImmediate ponyfill

    Install

    $ npm install set-immediate-shim
    

    Usage

    const setImmediateShim = require('set-immediate-shim');
     
    setImmediateShim(() => {
        console.log('2');
    });
     
    console.log('1');
     
    //=> 1
    //=> 2

    Related

    • p-immediate - Returns a promise resolved in the next event loop - think setImmediate()

    License

    MIT © Sindre Sorhus

    Install

    npm i set-immediate-shim

    DownloadsWeekly Downloads

    3,260,225

    Version

    2.0.0

    License

    MIT

    Unpacked Size

    2.56 kB

    Total Files

    4

    Last publish

    Collaborators

    • avatar