Packages

@tootallnate/once

3.0.1 · 9 Feb 2026MIT60.7M / weekRepositoryHomepagenpmAtom feed

Your version

2.0.0

major22 Sep 2021Where it was published

2.0.1 is the newest release of 2.x.

In short

1 breaking2 new2 fixed

  • Breaking

    Big refactor for v2

Security

1 advisory affects 2.0.0; 2.0.1 fixes them

Release note

Major Changes

  • Breaking

    Big refactor for v2

    • Returns a regular Promise instead of CancelablePromise.

    • The Promise is strongly typed when posssible. This is the main new feature.

    • Always returns the full array of arguments passed to the event handler (i.e. what was previously once.spread() is now the regular once()).

    • Compatible with AbortController to remove event listeners before the Promise has been fulfilled.

    • Requires TypeScript v4 or newer.

    • Jest tests running CI via GitHub Actions.

Minor Changes

  • Add README.md: d00821f

  • Create LICENSE

Patches

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.