Closed JordyMoos closed 5 years ago
Thanks for the issue! Make sure it satisfies this checklist. My human colleagues will appreciate it!
Here is what to expect next, and if anyone wants to comment, keep these things in mind.
I think adding this type would detract from the clarity of the API because now to understand Http.request
you have to start jumping around. So I get that it'd be convenient once you already know things, but the other concern is a bigger design goal.
Ok, thanks for answering the issue
Can we have a type alias for the argument going to Http.request?
Current:
Requested:
Because now i have two choices:
Put the whole record in all the functions that want to receive and return that record.
Make an alias myself. But the issue is that i have one request handlers that use that. And also multiple interceptors that use that record. Creating the alias in the handler gives me circular dependencies. So the only option is to move the type alias into an other file where they both depend on.
I think it does make sense to create the alias in this package