Talking about: https://github.com/clerk/javascript/blob/main/packages/backend/src/tokens/clerkRequest.ts#L106
Why does clerk clone the whole request, instead of just what it actually needs for auth? It might cause trouble if the body was already read via req.body.text() or similar.
E.g. we could avoid issues by just doing:
new Request(request.url, {
method: request.method,
headers: request.headers,
})
What do you think? I'm happy to start a PR.
Talking about: https://github.com/clerk/javascript/blob/main/packages/backend/src/tokens/clerkRequest.ts#L106
Why does clerk clone the whole request, instead of just what it actually needs for auth? It might cause trouble if the body was already read via
req.body.text()or similar.E.g. we could avoid issues by just doing:
What do you think? I'm happy to start a PR.