Debounce promise-returning & async functions.

Overview

perfect-debounce

npm version npm downloads Github Actions Codecov

An improved debounce function with Promise support.

  • Well tested debounce implementation
  • Native Promise support
  • Avoid duplicate calls while promise is being resolved
  • Configurable trailing and leading behavior

Usage

Install package:

# npm
npm install perfect-debounce

# yarn
yarn install perfect-debounce

# pnpm
pnpm install perfect-debounce

Import:

// ESM
import { debounce } from 'perfect-debounce'

// CommonJS
const { debounce } = require('perfect-debounce')

Debounce function:

const debounced = debounce(async () => {
  // Some heavy stuff
}, 25)

When calling debounced, it will wait at least for 25ms as configured before actually calling our function. This helps to avoid multiple calls.

To avoid initial wait, we can set leading: true option. It will cause function to be immediately called if there is no other call:

const debounced = debounce(async () => {
  // Some heavy stuff
}, 25, { leading: true })

If executing async function takes longer than debounce value, duplicate calls will be still prevented a last call will happen. To disable this behavior, we can set trailing: false option:

const debounced = debounce(async () => {
  // Some heavy stuff
}, 25, { trailing: false })

πŸ’» Development

  • Clone this repository
  • Enable Corepack using corepack enable (use npm i -g corepack for Node.js < 16.10)
  • Install dependencies using pnpm install
  • Run interactive tests using pnpm dev

License

Made with πŸ’›

Based on sindresorhus/p-debounce.

Published under MIT License.

Comments
  • chore(deps): update pnpm to v6.32.23

    chore(deps): update pnpm to v6.32.23

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 6.32.10 -> 6.32.23 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v6.32.23

    Compare Source

    Patch Changes
    • Packages that should be built are always cloned or copied from the store. This is required to prevent the postinstall scripts from modifying the original source files of the package #​4898.

    v6.32.22

    Compare Source

    Patch Changes
    • Don't fail when the cafile setting is specified #​4877. This fixes a regression introduced in pnpm v6.32.21.
    • Add better hints to the peer dependency issue errors.

    v6.32.21

    Compare Source

    Patch Changes

    • Report only the first occurence of a deprecated package.

    v6.32.20

    Compare Source

    Patch Changes
    • Suggest to update using Corepack when pnpm was installed via Corepack.
    • It should be possible to install a git-hosted package that has no package.json file #​4822.
    • When the same package is found several times in the dependency graph, correctly autoinstall its missing peer dependencies at all times #​4820.

    v6.32.19

    Compare Source

    Patch Changes
    • Improve the performance of the build sequence calculation step #​4815.
    • Correctly detect repeated dependency sequence during resolution #​4813.

    v6.32.18

    Compare Source

    Patch Changes
    • Don't fail on projects with linked dependencies, when auto-install-peers is set to true #​4796.
    • NODE_ENV=production pnpm install --dev should only install dev deps #​4745.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.17...v6.32.18

    v6.32.17

    Compare Source

    Patch Changes

    • Correctly detect the active Node.js version, when the pnpm CLI is bundled to an executable #​4203.

    v6.32.16

    Compare Source

    Patch Changes
    • When auto-install-peers is set to true, automatically install missing peer dependencies without writing them to package.json as dependencies. This makes pnpm handle peer dependencies the same way as npm v7 #​4776.

    v6.32.15

    Compare Source

    Patch Changes
    • Don't fail to create the command shim files if the target directory doesn't exist.
    • pnpm setup should not fail on Windows if PNPM_HOME is not yet in the system registry #​4757
    • pnpm dlx shouldn't modify the lockfile in the current working directory #​4743.

    v6.32.14

    Compare Source

    Patch Changes
    • Sanitize the directory names created inside node_modules/.pnpm and inside the global store #​4716
    • Resolve commits from GitHub via https #​4734.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.13...v6.32.14

    v6.32.13

    Compare Source

    Patch Changes

    • pnpm setup should update the config of the current shell, not the preferred shell.
    • pnpm dlx should work with git-hosted packages. For example: pnpm dlx gengjiawen/envinfo #​4714.
    • pnpm setup should not override the PNPM_HOME env variable on Windows, unless --force is used.
    • All arguments after pnpm create <pkg> should be passed to the executed create app package. So pnpm create next-app --typescript should work`.
    • pnpm run --stream should prefix the output with directory #​4702

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.12...v6.32.13

    v6.32.12

    Compare Source

    Patch Changes
    • Use Yarn's compatibility database to patch broken packages in the ecosystem with package extensions.
    • pnpm dlx should work when the bin name of the executed package isn't the same as the package name #​4672.
    • pnpm prune works in a workspace #​4647.
    • pnpm prune does not remove hoisted dependencies.
    • pnpm dlx should print messages about installation to stderr #​1698.

    v6.32.11

    Compare Source

    Patch Changes
    • pnpm publish should work correctly in a workspace, when the latest npm CLI is installed #​4348.
    • Installation shouldn't fail when a package from node_modules is moved to the node_modules/.ignored subfolder and a package with that name is already present in `node_modules/.ignored' #​4626.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.10...v6.32.11


    Configuration

    πŸ“… Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    πŸ”• Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, click this checkbox.

    This PR has been generated by Mend Renovate. View repository job log here.

    opened by renovate[bot] 0
  • chore(deps): update pnpm to v6.32.10

    chore(deps): update pnpm to v6.32.10

    WhiteSource Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 6.32.4 -> 6.32.10 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v6.32.10

    Compare Source

    Patch Changes

    • It should be possible to use a chain of local file dependencies #​4611.
    • Filtering by directory should work with directories that have unicode chars in the name #​4595.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.9...v6.32.10

    v6.32.9

    Compare Source

    Patch Changes

    • Fix an error with peer resolutions, which was happening when there was a circular dependency and another dependency that had the name of the circular dependency as a substring.

    • When pnpm exec is running a command in a workspace project, the commands that are in the dependencies of that workspace project should be in the PATH #​4481.

    • Hide "WARN deprecated" messages on loglevel error #​4507

      Don't show the progress bar when loglevel is set to warn or error.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.8...v6.32.9

    v6.32.8

    Compare Source

    Patch Changes
    • Don't check the integrity of the store with the package version from the lockfile, when the package was updated #​4580.
    • Don't update a direct dependency that has the same name as a dependency in the workspace, when adding a new dependency to a workspace project #​4575.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.7...v6.32.8

    v6.32.7

    Compare Source

    Patch Changes

    • Setting the auto-install-peers to true should work.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.6...v6.32.7

    v6.32.6

    Compare Source

    Patch Changes

    • Linked in dependencies should be considered when resolving peer dependencies #​4541.
    • Peer dependency should be correctly resolved from the workspace, when it is declared using a workspace protocol #​4529.

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.32.5...v6.32.6

    v6.32.5

    Compare Source


    Configuration

    πŸ“… Schedule: At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    πŸ”• Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, click this checkbox.

    This PR has been generated by WhiteSource Renovate. View repository job log here.

    opened by renovate[bot] 0
  • chore(deps): update actions/setup-node action to v3

    chore(deps): update actions/setup-node action to v3

    WhiteSource Renovate

    This PR contains the following updates:

    | Package | Type | Update | Change | |---|---|---|---| | actions/setup-node | action | major | v2 -> v3 |


    Release Notes

    actions/setup-node

    v3

    Compare Source


    Configuration

    πŸ“… Schedule: At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    πŸ”• Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, click this checkbox.

    This PR has been generated by WhiteSource Renovate. View repository job log here.

    opened by renovate[bot] 0
  • chore(deps): update actions/checkout action to v3

    chore(deps): update actions/checkout action to v3

    WhiteSource Renovate

    This PR contains the following updates:

    | Package | Type | Update | Change | |---|---|---|---| | actions/checkout | action | major | v2 -> v3 |


    Release Notes

    actions/checkout

    v3

    Compare Source


    Configuration

    πŸ“… Schedule: At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    πŸ”• Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, click this checkbox.

    This PR has been generated by WhiteSource Renovate. View repository job log here.

    opened by renovate[bot] 0
  • chore(deps): update pnpm to v6.32.4

    chore(deps): update pnpm to v6.32.4

    WhiteSource Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 6.32.3 -> 6.32.4 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v6.32.4

    Compare Source

    Patch Changes
    • Show a friendly error message when it is impossible to get the current Git branch name during publish #​4488.
    • When checking if the lockfile is up-to-date, an empty dependenciesMeta field in the manifest should be satisfied by a not set field in the lockfile #​4463.
    • It should be possible to reference a workspace project that has no version specified in its package.json #​4487.

    Configuration

    πŸ“… Schedule: At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    πŸ”• Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, click this checkbox.

    This PR has been generated by WhiteSource Renovate. View repository job log here.

    opened by renovate[bot] 0
  • feat: wait for promise

    feat: wait for promise

    This refactor is merging debunce.promise with debounce so that we avoid calling fn again after debounce delay and while the previous promise is resolving.

    A downside of this approach is that calls will be ignored while the previous promise is being resolved. This causes missing last results. To fix this, we keep the last trailing args and call again after current promise resolves.

    opened by pi0 0
  • chore(deps): update all non-major dependencies

    chore(deps): update all non-major dependencies

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 6.32.23 -> 6.35.1 | age | adoption | passing | confidence | | time-span | ^5.0.0 -> ^5.1.0 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v6.35.1

    Compare Source

    Patch Changes

    • Replace environment variable placeholders with their values, when reading .npmrc files in subdirectories inside a workspace #​2570.
    • Don't fail if cannot override the name field of the error object #​5572.

    v6.35.0

    Compare Source

    Patch Changes

    • Installing a package with bin that points to an .exe file on Windows #​5159.

    • Ignore the always-auth setting.

      pnpm will never reuse the registry auth token for requesting the package tarball, if the package tarball is hosted on a different domain.

      So, for example, if your registry is at https://company.registry.com/ but the tarballs are hosted at https://tarballs.com/, then you will have to configure the auth token for both domains in your .npmrc:

      @&#8203;my-company:registry=https://company.registry.com/
      //company.registry.com/=SOME_AUTH_TOKEN
      //tarballs.com/=SOME_AUTH_TOKEN
      
    • When an error happens during installation of a subdependency, print some context information in order to be able to locate that subdependency. Print the exact chain of packages that led to the problematic dependency.

    v6.34.0

    Compare Source

    Minor Changes

    Full Changelog: https://github.com/pnpm/pnpm/compare/v6.33.1...v6.34.0

    v6.33.1

    Compare Source

    Patch Changes

    • Don't print any info messages about .pnpmfile.cjs #​5027.
    • Do not print a package with unchanged version in the installation summary #​5032.
    • Remove file reporter logging. Logged file is not useful #​4949.

    v6.33.0

    Compare Source

    v6.32.25

    Compare Source

    Patch Changes

    • pnpm audit --fix should not add an override for a vulnerable package that has no fixes released.
    • Resolve native workspace path for case-insensitive file systems #​4904.
    • pnpm env use should throw an error on a system that use the MUSL libc.

    v6.32.24

    Compare Source

    Patch Changes

    • Don't crash when pnpm update --interactive is cancelled with Ctrl+c.

    • The use-node-version setting should work with prerelease Node.js versions. For instance:

      use-node-version=18.0.0-rc.3
      
    sindresorhus/time-span

    v5.1.0

    Compare Source


    Configuration

    πŸ“… Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    πŸ‘» Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    opened by renovate[bot] 0
  • chore(deps): update pnpm to v7

    chore(deps): update pnpm to v7

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 6.32.23 -> 7.22.0 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v7.22.0

    Compare Source

    Minor Changes

    • The pnpm list and pnpm why commands will now look through transitive dependencies of workspace: packages. A new --only-projects flag is available to only print workspace: packages.
    • pnpm exec and pnpm run command support --resume-from option. When used, the command will executed from given package #​4690.
    • Expose the npm_command environment variable to lifecycle hooks & scripts.

    Patch Changes

    • Fix a situation where pnpm list and pnpm why may not respect the --depth argument.
    • Report to the console when a git-hosted dependency is built #​5847.
    • Throw an accurate error message when trying to install a package that has no versions, or all of its versions are unpublished #​5849.
    • replace dependency is-ci by ci-info (is-ci is just a simple wrapper around ci-info).
    • Only run prepublish scripts of git-hosted dependencies, if the dependency doesn't have a main file. In this case we can assume that the dependencies has to be built.
    • Print more contextual information when a git-hosted package fails to be prepared for installation #​5847.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.21.0

    Compare Source

    Minor Changes

    • The pnpm dlx command supports the --shell-mode (or -c) option. When used, the script is executed by a shell #​5679.

    Patch Changes

    • The config command should work with the --location=global CLI option #​5841.
    • Only the pnpm add --global <pkg> command should fail if there is no global pnpm bin directory in the system PATH #​5841.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.20.0

    Compare Source

    Minor Changes

    • pnpm gets its own implementation of the following commands:

      • pnpm config get
      • pnpm config set
      • pnpm config delete
      • pnpm config list

      In previous versions these commands were passing through to npm CLI.

      PR: #​5829 Related issue: #​5621

    • Add show alias to pnpm view #​5835.

    • pnpm reads settings from its own global configuration file at $XDG_CONFIG_HOME/pnpm/rc #​5829.

    • Add the 'description'-field to the licenses output #​5836.

    Patch Changes

    • pnpm rebuild should not fail if node_modules was created by pnpm version 7.18 or older #​5815.
    • pnpm env should print help.
    • Run the prepublish scripts of packages installed from Git #​5826.
    • pnpm rebuild should print a better error message when a hoisted dependency is not found #​5815.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.19.0

    Compare Source

    Minor Changes

    • New setting supported in the package.json that is in the root of the workspace: pnpm.requiredScripts. Scripts listed in this array will be required in each project of the worksapce. Otherwise, pnpm -r run <script name> will fail #​5569.
    • When the hoisted node linker is used, preserve node_modules directories when linking new dependencies. This improves performance, when installing in a project that already has a node_modules directory #​5795.
    • When the hoisted node linker is used, pnpm should not build the same package multiple times during installation. If a package is present at multipe locations because hoisting could not hoist them to a single directory, then the package should only built in one of the locations and copied to the rest #​5814.

    Patch Changes

    • pnpm rebuild should work in projects that use the hoisted node linker #​5560.
    • pnpm patch should print instructions about how to commit the changes #​5809.
    • Allow the -S flag in command shims pnpm/cmd-shim#​42.
    • Don't relink injected directories if they were not built #​5792.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.18.2

    Compare Source

    Patch Changes

    • Added --json to the pnpm publish --help output #​5773.
    • pnpm update should not replace workspace:*, workspace:~, and workspace:^ with workspace:<version> #​5764.
    • The fatal error should be printed in JSON format, when running a pnpm command with the --json option #​5710.
    • Throw an error while missing script start or file server.js #​5782.
    • pnpm license list should not fail if a license file is an executable #​5740.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.18.1

    Compare Source

    Patch Changes

    • The update notifier should suggest using the standalone script, when pnpm was installed using a standalone script #​5750.
    • Vulnerabilities that don't have CVEs codes should not be skipped by pnpm audit if an ignoreCves list is declared in package.json #​5756.
    • It should be possible to use overrides with absolute file paths #​5754.
    • pnpm audit --json should ignore vulnerabilities listed in auditConfig.ignoreCves #​5734.
    • pnpm licenses should print help, not just an error message #​5745.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.18.0

    Compare Source

    Minor Changes

    • Overrides may be defined as a reference to a spec for a direct dependency by prefixing the name of the package you wish the version to match with a `# pnpm.

      {
        "dependencies": {
          "foo": "^1.0.0"
        },
        "overrides": {
          // the override is defined as a reference to the dependency
          "foo": "$foo",
          // the referenced package does not need to match the overridden one
          "bar": "$foo"
        }
      }
      

      Issue: #​5703

    Patch Changes

    • pnpm audit should work when the project's package.json has no version field #​5728
    • Dependencies specified via * should be updated to semver ranges by pnpm update #​5681.
    • It should be possible to override a dependency with a local package using relative path from the workspace root directory #​5493.
    • Exit with non-zero exit code when child process exits with a non-zero exit clode #​5525.
    • pnpm add should prefer local projects from the workspace, even if they use prerelease versions #​5316

    Our Gold Sponsors

    Our Silver Sponsors

    v7.17.1

    Compare Source

    Patch Changes

    • pnpm set-script and pnpm pkg are passed through to npm #​5683.
    • pnpm publish <tarball path> should exit with non-0 exit code when publish fails #​5396.
    • readPackage hooks should not modify the package.json files in a workspace #​5670.
    • Comments in package.json5 are preserver #​2008.
    • pnpm setup should create PNPM_HOME as a non-expandable env variable on Windows #​4658.
    • Fix the CLI help of the pnpm licenses command.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.17.0

    Compare Source

    Minor Changes

    • Added a new command pnpm licenses list, which displays the licenses of the packages #​2825

    Patch Changes

    • pnpm update --latest !foo should not update anything if the only dependency in the project is the ignored one #​5643.
    • pnpm audit should send the versions of workspace projects for audit.
    • Hoisting with symlinks should not override external symlinks and directories in the root of node_modules.
    • The pnpm.updateConfig.ignoreDependencies setting should work with multiple dependencies in the array #​5639.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.16.1

    Compare Source

    Patch Changes
    • Sync all injected dependencies when hoisted node linker is used #​5630
    Our Gold Sponsors
    Our Silver Sponsors

    v7.16.0

    Compare Source

    Minor Changes

    • Support pnpm env list to list global or remote Node.js versions #​5546.

    Patch Changes

    • Replace environment variable placeholders with their values, when reading .npmrc files in subdirectories inside a workspace #​2570.
    • Fix an error that sometimes happen on projects with linked local dependencies #​5327.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.15.0

    Compare Source

    Minor Changes

    • Support --format=json option to output outdated packages in JSON format with outdated command #​2705.

      pnpm outdated --format=json
      #or
      pnpm outdated --json
      
    • A new setting supported for ignoring vulnerabilities by their CVEs. The ignored CVEs may be listed in the pnpm.auditConfig.ignoreCves field of package.json. For instance:

      {
        "pnpm": {
          "auditConfig": {
            "ignoreCves": [
              "CVE-2019-10742",
              "CVE-2020-28168",
              "CVE-2021-3749",
              "CVE-2020-7598"
            ]
          }
        }
      }
      

    Patch Changes

    • The reporter should not crash when the CLI process is kill during lifecycle scripts execution #​5588.
    • Installation shouldn't fail when the injected dependency has broken symlinks. The broken symlinks should be just skipped #​5598.

    Our Gold Sponsors

    Our Silver Sponsors

    v7.14.2

    Compare Source

    Patch Changes
    • Don't fail if cannot override the name field of the error object #​5572.
    • Don't fail on rename across devices.
    Our Gold Sponsors
    Our Silver Sponsors
    Mend Renovate. View repository job log here.

    opened by renovate[bot] 0
  • Dependency Dashboard

    Dependency Dashboard

    This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

    Open

    These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

    Detected dependencies

    github-actions
    .github/workflows/ci.yml
    • actions/checkout v3
    • actions/setup-node v3
    npm
    package.json
    • in-range ^3.0.0
    • time-span ^5.0.0
    • pnpm 6.32.23

    • [ ] Check this box to trigger a request for Renovate to run again on this repository
    opened by renovate[bot] 0
  • Owner
    unjs
    Unified JavaScript Tools
    unjs
    Adds promise support (rejects(), doesNotReject()) to tape by decorating it using tape-promise.

    Tape With Promises Adds promise support (rejects(), doesNotReject()) to tape by decorating it using tape-promise. Install npm install --save-dev @smal

    Small Technology Foundation 3 Mar 21, 2022
    Converts an iterable, iterable of Promises, or async iterable into a Promise of an Array.

    iterate-all A utility function that converts any of these: Iterable<T> Iterable<Promise<T>> AsyncIterable<T> AsyncIterable<Promise<T>> Into this: Prom

    Lily Scott 8 Jun 7, 2022
    Add class(es) to DOM elements while waiting for async action. Promise or callback.

    jquery.loading Add class(es) to DOM elements while waiting for async action. Promise or callback. Install The simplest way is to include loading.js in

    Dumitru Uzun 1 Mar 26, 2022
    A workshop about JavaScript iteration protocols: iterator, iterable, async iterator, async iterable

    JavaScript Iteration protocol workshop A workshop about JavaScript iteration protocols: iterator, iterable, async iterator, async iterable by @loige.

    Luciano Mammino 96 Dec 20, 2022
    A NodeJS Replit API package wrapped around GraphQL, returning JSON data for easy use.

    repl-api.js A NodeJS Replit API package wrapped around GraphQL, returning JSON data for easy use. Contents: About Quickstart Pre-installation Installa

    kokonut 5 May 20, 2022
    Well-tested utility functions dealing with async iterables

    aitertools This library provides a well-tested collection of small utility functions dealing with async iterables. You can think of it as LINQ or aite

    Hong Minhee (ζ΄ͺ 民憙) 11 Aug 15, 2022
    Functions Recipes is a library of examples to help you getting started with Salesforce Functions and get used to their main features.

    Functions Recipes Introduction Salesforce Functions lets you use the Salesforce Platform for building event-driven, elastically scalable apps and expe

    Trailhead Apps 172 Dec 29, 2022
    Init a target by promise only once.

    once-init ?? Let Promise Function Executed Only Once. The Promise will be executed when the attribute target is called for the first time, and the Pro

    Xmo 65 Dec 26, 2022
    Javascript client for Sanity. Works in node.js and modern browsers (older browsers needs a Promise polyfill).

    @sanity/client Javascript client for Sanity. Works in node.js and modern browsers (older browsers needs a Promise polyfill). Requirements Sanity Clien

    Sanity 23 Nov 29, 2022
    Promise-based utility to control modal states in React

    Promise-based utility to control modal states in React Zero-dependency library that easily integrates with your existing UI components and allows you

    Thiago Zanivan 8 Dec 5, 2022
    A simple Node.js package that helps you not to look up JavaScript promise syntax every time you use it.

    A simple Node.js package that helps you not to look up JavaScript promise syntax every time you use it. Simple: Provides abstraction of the promise sy

    Saad Irfan ⚑️ 9 Oct 8, 2022
    Promise based HTTP client for the browser and node.js

    axios Promise based HTTP client for the browser and node.js New axios docs website: click here Table of Contents Features Browser Support Installing E

    axios 98k Jan 5, 2023
    Base provides advanced Promise Queue Manager, Custom Console Logger and other utilities.

    Base Base provides frequently used functionality like cutome logger, response helper, Custom Promise and Instance composer. These are used in almost a

    PLG Works 14 Jun 14, 2022
    Plug-and-play, faster-than-native promise/callback event emitter

    kNow Blazing-fast callback/promise-based events with a tiny footprint What is this? With kNow (pronounced "now"β€”the k's silent), JavaScript event mana

    Elijah Bodden 25 Sep 11, 2022
    A Promise-compatible abstraction that defers resolving/rejecting promises to another closure.

    Deferred Promise The DeferredPromise class is a Promise-compatible abstraction that defers resolving/rejecting promises to another closure. This class

    Open Draft 21 Dec 15, 2022
    utility library for promise, support both commonjs and ESM

    promising-utils A utility library for promise, supports both commonjs and ESM npm install promising-utils --save yarn add promising-utils wait Used wh

    Qiang Li 4 Oct 18, 2022
    βš–οΈ Limit an async function's concurrency with ease!

    limit-concur Limit an async function's concurrency with ease! Install $ npm i limit-concur Usage import got from 'got' import limitConcur from 'limit-

    Tomer Aberbach 19 Apr 8, 2022
    Async cache with dedupe support

    async-cache-dedupe async-cache-dedupe is a cache for asynchronous fetching of resources with full deduplication, i.e. the same resource is only asked

    Matteo Collina 299 Dec 8, 2022
    This simple project, show how work with async Fetch, function component and class component

    Getting Started with Create React App This project was bootstrapped with Create React App. Available Scripts In the project directory, you can run: np

    DaliyaAsel 2 Feb 17, 2022