Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork21.8k
refactor: replaceonce package with internal implementation#6591
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Pull Request Overview
This PR removes the external "once" package and "wrappy" from the dependency tree and replaces it with an internal utility function to simplify the codebase.
- Removed external dependency "once" from package.json
- Introduced an internal "once" implementation in lib/utils.js
- Updated lib/application.js to reference the new internal implementation
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| package.json | Removed the "once" package dependency |
| lib/utils.js | Added a new internal implementation of "once" |
| lib/application.js | Updated the import to use the internal "once" function |
bjohansebas left a comment• edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
This has already been tried before, see#6555
Phillip9587 commentedJun 25, 2025
@bjohansebas I'm sorry I missed the earlier PR. I didn't get a chance to review it before it was closed. I thought we had a policy about leaving PRs open long enough to allow contributors to comment - maybe we can revisit that if needed. I'd like to respond to a few points raised in#6555:
I double-checked all 3 orgs, and as far as I can tell,
Totally understand that reasoning. However, Please don’t close this PR just yet. Thanks! |
ctcpip commentedJun 25, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
my position on this is unchanged. please see these particular comments:
pulling in dependencies is not a bad thing, andeliminating dependencies is not necessarily a good thing note also that the in any case, as I said in the comment linked above, I think that further discussion is better suited for an actualdiscussion |
This comment was marked as duplicate.
This comment was marked as duplicate.
Sorry, something went wrong.
Uh oh!
There was an error while loading.Please reload this page.
bjohansebas commentedJun 26, 2025
I still believe we shouldn't remove this dependency. I know my position isn't reflected in the PR, but I did share it on Slack, where I agreed with Jordan and, in general, with the other members who are opposed to removing this dependency to add it directly here. |
This PR removes the external
oncepackage and replaces it with a modern, internal utility function. The goal is to reduce unnecessary dependencies and simplify the codebase without altering runtime behavior.onceandwrappyapp.listen) to use the new localoncefunctionNo functional changes expected — behavior remains consistent with the previous implementation.