Skip to content

Create an "Array-Like" type #708

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

Closed
dmethvin opened this issue Apr 8, 2015 · 1 comment
Closed

Create an "Array-Like" type #708

dmethvin opened this issue Apr 8, 2015 · 1 comment
Assignees

Comments

@dmethvin
Copy link
Member

dmethvin commented Apr 8, 2015

As suggested by @timmywil in #686 (comment), add an "Array-Like" type to our Types page to clarify when a method accepts more than just Array. Perhaps something like this:

Array-Like - Either a true JavaScript Array or a JavaScript Object that contains a numeric length property. This latter case includes array-like objects commonly encountered in web-based code such as the Arguments object and the NodeList object returned by many DOM methods. Note that when a jQuery API accepts either plain Objects or Array-Like objects, a plain Object with a numeric length property will trigger the Array-Like behavior.

@arthurvr
Copy link
Member

arthurvr commented Apr 9, 2015

Yup, 👍. I'll take this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

2 participants