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
fix(NODE-3386): listCollections result type definition #2866
Conversation
Fwiw, it can come pretty close: TypeScript playground |
Oo thanks for the insight, I'll give that a try |
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.
LGTM 👍
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.
small typo, otherwise LGTM :)
Co-authored-by: Daria Pardue <81593090+dariakp@users.noreply.github.com>
d008033
to
b7c35cb
Compare
Rebased, should clear up the unrelated error in the last CI run |
The listCollections cursor now has a generic that defaults to a flexible CollectionInfo type. Typescript can't change a return type bases on a runtime boolean so I show example usage in the added types test of how one can use the API pretty succinctly.