You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd love to see a type-safe return value from the multi() method on various APIs. I know this is easier said than done — I can't think of a way to do it when passing an array of selection strings — but I there are other ways it could work. Something like:
@smikula, I would be interested in seeing your ideas. I added the multi calls as more of an afterthought, so they don't fit in as well as the other calls.
Alternately, you could just define a big return type from multi with all properties there but optional. That's a little annoying to work with as a consumer, but way easier for the library to code!
I'd love to see a type-safe return value from the
multi()
method on various APIs. I know this is easier said than done — I can't think of a way to do it when passing an array of selection strings — but I there are other ways it could work. Something like:Or:
Or with a little ingenuity I think even this could work:
What do you think? If you're interested, I'd be up for working on a PR.
The text was updated successfully, but these errors were encountered: