Sets response headers allowing requests from browsers that send preflight OPTIONS requests. Previously using @aws-sdk/client-lambda returned CORS errors. Now requests and responses can be sent.
Test Plan: Build and run locally. Ensure curl -XPOST still works. Ensure requests from browsers now work and from @aws-sdk/client-lambda Test steps added to Contributing.md. Ensure make integ-tests-and-compile passes
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Fixes https://github.com/aws/aws-lambda-runtime-interface-emulator/issues/16
Sets response headers allowing requests from browsers that send preflight OPTIONS requests. Previously using @aws-sdk/client-lambda returned CORS errors. Now requests and responses can be sent.
Test Plan: Build and run locally. Ensure curl -XPOST still works. Ensure requests from browsers now work and from @aws-sdk/client-lambda Test steps added to Contributing.md. Ensure
make integ-tests-and-compile
passesBy submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.