Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Always run limited functions asynchronously #28

Commits on May 15, 2020

  1. fix: always run limit fns asynchronously

    This modifies the generator function returned from plimit to always
    run functions passed to limit asynchronously.
    
    This is done by modifying the enqueue method to always push the function
    provided to the generator function onto the queue and then scheduling a
    function to run asynchronously to dequeue and run that function.
    
    I thought using using `Promise.resolve().then()` was a nice way to
    schedule that dequeuing function asynchronously because it wasn't too
    node-specific or browser-specific, but I'm happy to do something else
    like preferring `process.nextTick` and then falling back to `setTimeout`
    if `process.nextTick` isn't available.
    copperwall committed May 15, 2020
    Configuration menu
    Copy the full SHA
    247c24f View commit details
    Browse the repository at this point in the history

Commits on May 16, 2020

  1. Configuration menu
    Copy the full SHA
    9692609 View commit details
    Browse the repository at this point in the history

Commits on May 17, 2020

  1. Configuration menu
    Copy the full SHA
    be61486 View commit details
    Browse the repository at this point in the history

Commits on May 18, 2020

  1. Update index.js

    sindresorhus authored May 18, 2020
    Configuration menu
    Copy the full SHA
    08619f6 View commit details
    Browse the repository at this point in the history