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

.un alias for .removeListener in events module #3838

Closed
wants to merge 1 commit into from
Closed

.un alias for .removeListener in events module #3838

wants to merge 1 commit into from

Conversation

rifler
Copy link

@rifler rifler commented Nov 15, 2015

.addListener -> .on
.removeListener -> .un

@cjihrig
Copy link
Contributor

cjihrig commented Nov 15, 2015

Related - #540, #1064

@mscdex
Copy link
Contributor

mscdex commented Nov 15, 2015

-1. un looks awkward since it's a prefix and not a word by itself, and it looks too close to on.

@mscdex mscdex added the events Issues and PRs related to the events subsystem / EventEmitter. label Nov 15, 2015
@ChALkeR
Copy link
Member

ChALkeR commented Nov 15, 2015

-1. Does anyone else use that? If not, what's the reason for including it?

@ChALkeR ChALkeR added the feature request Issues that request new features to be added to Node.js. label Nov 15, 2015
@jasnell
Copy link
Member

jasnell commented Nov 16, 2015

-1. appreciate the idea of being able to type fewer characters but just not seeing the value here, not to mention that un and on are quite visually similar that it would likely lead to confusion.

@estliberitas
Copy link
Contributor

Maybe .off then like in EventEmitter2?

UPDATE: sorry, just read #540

@ronkorving
Copy link
Contributor

-1. I'm with @estliberitas here. If you're gonna add an alias (which I for one don't need), .off would be a clearer name.

@jasnell
Copy link
Member

jasnell commented Nov 16, 2015

@rifler ... thank you very much for the PR. Given the -1's, I'm going to close this.

@jasnell jasnell closed this Nov 16, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
events Issues and PRs related to the events subsystem / EventEmitter. feature request Issues that request new features to be added to Node.js.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants