-
Notifications
You must be signed in to change notification settings - Fork 131
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
Associate a req with res and vice versa #45
Comments
@jasonkarns, thanks for pointing this out. I think your last suggestion is the way to go. We should probably simulate the way Express does it at the moment. Express assigns these to each other at the beginning of the middleware lifecycle, in the init middleware. Regardless of how we do it, I suspect this will be a breaking change. If we find a way to enable the feature without introducing any breaking changes, we will likely include it in the We're open to suggestions, so if you have any ideas on how to enable this feature without an breaking changes, by all means share them with us. If you decide to submit a PR, please read our new contributing guidelines. Soon we will be publishing the roadmap for our |
So something like: |
Actually, after studying the Express |
Where does this leave this issue? I don't see a 2.x branch in development or anything. Does this mean you don't want any PR for it? |
|
Cool. I'll wait till then to do any work on it. |
@jasonkarns, I've added our roadmap for our |
Stale issue message |
req.res should exist, as should res.req.
I'm not sure if there should be a single api method that creates both req and res under the hood (and returns both as array? or object? or just one or the other?)
Or if the createRequest/createResponse methods should accept the other half of the pair and do the wireup?
Or if there should be a separate utility method that just accepts already-created req/res mocks and associates them.
Thoughts?
I'd be happy to work on the PR, once a direction is decided that fits the goals of the project.
The text was updated successfully, but these errors were encountered: