Skip to content

Conversation

@BrennerSpear
Copy link

Sometimes the return type of all() is an object, not an array

Sometimes the return type of `all()` is an object, not an array
@acurrieclark
Copy link

acurrieclark commented Jul 10, 2022

Excellent. Came here this morning with the express intention of submitting an identical PR.

* The all method returns the underlying array or object represented by the collection.
*/
all(): Item[];
all(): Item[] | Record<string,Item>;

Choose a reason for hiding this comment

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

I suggest:

  all(): Item[] | Record<unkown, Item>;

(see: #304 (comment))

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants