wingleung / remix-aws

AWS adapter for Remix
https://www.npmjs.com/package/remix-aws
MIT License
22 stars 6 forks source link

Fix getting cookies from headers. #41

Open gotgenes opened 1 week ago

gotgenes commented 1 week ago

Fixes an issue in the API Gateway v2 adapter where the call to headers.raw() throws the following error:

TypeError: nodeResponse.headers.raw is not a function

As described in remix-run/remix#4354, the headers.raw() method is not available in the Headers class in Node.js. This change replaces the headers.raw() method with headers.getSetCookie() from the Fetch API to fix the issue.

This also updates the dependencies to modern versions of TypeScript and remix-run.