RFC: add support for Service Request and Response type #2125
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi,
This PR would likely be a breaking change, so I am actually hoping to make it into
dove
instead ofcrow
. I have most of the description written in this-repo that I created to showcase, but I will put some of key info here.For the longest time, I have been wanting to have some ways to allow me to define a different set of request/response interface since it can be different (and it is for most cases that I have encounter). There have been some chats about this in
slack
as well, and I thought I can start making some changes and see if this can be accepted, and I'm sure can be further improved as well.Objective
Allow to declare a different set of interface for
Request
andResponse
which can also greatly improve dev-experience.Example
Result
For more details, and example, please refer to feathers-request-response-demo
If there is a better way to do this, I would like to have your feedback. This should not affect any actual functionality of the application, it all just providing better typing's for typescript developers.
Thanks!