Yusuke Wada

Results 1706 comments of Yusuke Wada

@cjnoname So I can understand the behavior on the AWS Lambda, but I want to know if that does https://github.com/honojs/hono/pull/4166#issuecomment-2951308753 work for you?

> But the best approach is still to read the full body once at the beginning and cache it so all subsequent middlewares can share it. Using `await res.arrayBuffer()` will...

> For example, in your context, you could define a variable like bodyText (or any suitable name) to hold the content of res.body(). Then, middlewares like etag can simply read...

Do you mean changing this `res.clone().body` to `res.body` will work? https://github.com/honojs/hono/blob/4a1dd5f66b2b30d7576ea15171423a51b3ed1a59/src/middleware/etag/index.ts#L96 To: ```ts const hash = await generateDigest(res.body, generator) ```

@cjnoname I can understand. But can you answer the question? If not, we can't help you. Sorry.

My idea is the following: ```diff diff --git a/src/middleware/etag/digest.ts b/src/middleware/etag/digest.ts index 8c6b6f97..27c7941a 100644 --- a/src/middleware/etag/digest.ts +++ b/src/middleware/etag/digest.ts @@ -9,23 +9,25 @@ const mergeBuffers = (buffer1: ArrayBuffer | undefined, buffer2: Uint8Array):...

@MiguelsPizza See this benchmark: https://x.com/yusukebe/status/1926167681192886302 It's 3.5 times faster.

Hi @sharma-shray Thank you for the PR. Looks good. But next time, please follow the [@usualoma 's comment](https://github.com/honojs/hono/pull/3557#issuecomment-2436520634).

Hi @goisaki Thank you for the comment. Honestly, I don't have so many ideas now. Regarding `3`, it's the best use of GitHub Actions since we want everything on GitHub...

Dosu https://dosu.dev/ may help us.