Skip to content
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

fromWebHandler adapter to use Request -> Response handlers with h3 #490

Closed
1 task done
nksaraf opened this issue Aug 4, 2023 · 3 comments
Closed
1 task done

fromWebHandler adapter to use Request -> Response handlers with h3 #490

nksaraf opened this issue Aug 4, 2023 · 3 comments
Labels
enhancement New feature or request

Comments

@nksaraf
Copy link

nksaraf commented Aug 4, 2023

Describe the feature

An adapte analogous to fromNodeMiddleware that adapts a (request: Request) -> Response handler to an h3 event handler

Additional information

  • Would you be willing to help implement this feature?
@pi0 pi0 added the enhancement New feature or request label Aug 4, 2023
@pi0
Copy link
Member

pi0 commented Aug 4, 2023

Since h3 1.8 is web native, we have event.request (As normalized Request object) and we can directly return a Reponse from handlers.

Making wrapper would be mainly a shortcut for translating event.request to request but i think it is still something nice for adapter to be supported.

@nksaraf
Copy link
Author

nksaraf commented Aug 5, 2023

Ohh wait i didnt know there was event.request and Response support already.. that makes things incredibly easier

@pi0 pi0 closed this as completed in 6305080 Aug 8, 2023
@pi0
Copy link
Member

pi0 commented Aug 8, 2023

Added in 6305080

@pi0 pi0 mentioned this issue Aug 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants