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
We should implement trailers support for requests and responses behind a Deno-specific symbol that we can then swap out for the full API when standardized:
We add an --unstable only Deno.trailers unique symbol.
We add support for this symbol to Response, Request and the associated *Init objects. The field value would be Promise<Headers> or Promise<HeadersInit>, respectively
If we get support for this in the standard, Deno.trailers can be turned from a symbol into a string with the value trailers and marked as deprecated.
If a promise was provided in RequestInit for fetchor ResponseInit for Deno.serve, we'd await that promise before finalizing the associated HTTP transaction.
Initially this would only be supported for HTTP/2, however we could attempt to push support upstream to hyper for HTTP/1. I don't think that will be necessary, however.
The WhatWG discussion on trailers in requests and responses is picking up a bit and it looks like CloudFlare is interested in implementing this as well.
We should implement trailers support for requests and responses behind a Deno-specific symbol that we can then swap out for the full API when standardized:
Deno.trailers
unique symbol.Response
,Request
and the associated*Init
objects. The field value would bePromise<Headers>
orPromise<HeadersInit>
, respectivelyDeno.trailers
can be turned from a symbol into a string with the value trailers and marked as deprecated.RequestInit
forfetch
orResponseInit
forDeno.serve
, we'd await that promise before finalizing the associated HTTP transaction.Initially this would only be supported for HTTP/2, however we could attempt to push support upstream to hyper for HTTP/1. I don't think that will be necessary, however.
This would allow for something like this to work:
The text was updated successfully, but these errors were encountered: