-
-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Labels
umbrella issueThis issue contains a list of dependents of a package and tracks the progress in eachThis issue contains a list of dependents of a package and tracks the progress in each
Description
These three packages:
- once
- onetime
- one-time
They're somewhat useful but actually cover up bugs in many cases.
For example, some common usages in the wild are similar to the following:
const done = once(fn);
target.addEventListener('ev1', done);
target.addEventListener('ev2', done);This actually covers up the fact that it shouldn't be possible to call the function twice in the first place. Ideally, you'd remove the listeners once one has fired, for example.
Either way, it seems most usages of these modules don't need them.
Admittedly they do provide some functionality that may be useful to some people - so this isn't a blanket removal. Rather, we should remove them from packages which don't need them.
aldy505
Metadata
Metadata
Assignees
Labels
umbrella issueThis issue contains a list of dependents of a package and tracks the progress in eachThis issue contains a list of dependents of a package and tracks the progress in each