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

docs - Add helper-get-function-arity readme [skip ci] #6532

Merged
merged 4 commits into from
Oct 23, 2017

Conversation

athomann
Copy link
Contributor

Q                       A
Fixed Issues?
Patch: Bug Fix?
Major: Breaking Change?
Minor: New Feature?
Tests Added + Pass? Yes
Documentation PR 👍
Any Dependency Changes?

Add to the README for helper-get-function-arity
[skip ci]

@athomann athomann changed the title docs - Add helper-get-function-arity readme docs - Add helper-get-function-arity readme [skip ci] Oct 22, 2017
@babel-bot
Copy link
Collaborator

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/5451/

1 similar comment
@babel-bot
Copy link
Collaborator

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/5451/

Copy link
Member

@Andarist Andarist left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! Just slight changes are needed before merging

@@ -1,5 +1,19 @@
# @babel/helper-get-function-arity

Function that returns the number of arguments or operands that a function takes.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Im not sure what did u mean by operands here. Would be good to clarify it, but I think saying that it returns number of arguments is quite enough + clarification on what is considered to be an argument, for that we can just send readers to https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/length

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good. The operands part was taken from the wikipedia definition. Will make changes.

return false;
}

const argumentLength = getFunctionArity(method);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i would call it argumentsLength (plural)

@xtuc xtuc added the PR: Docs 📝 A type of pull request used for our changelog categories label Oct 23, 2017
@Andarist Andarist merged commit 3214c50 into babel:master Oct 23, 2017
@lock lock bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label May 1, 2018
@lock lock bot locked as resolved and limited conversation to collaborators May 1, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated A closed issue/PR that is archived due to age. Recommended to make a new issue PR: Docs 📝 A type of pull request used for our changelog categories
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants