Package Exports
- lambda-nodejs-response-helper
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (lambda-nodejs-response-helper) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Response helpers for AWS Lambda (nodejs)
Helper functions to create response objects for AWS Lambda
Installation
npm install --save github:egeniq/lambda-nodejs-response-helperUsage
'use strict';
const {createJsonResponse} = require('lambda-nodejs-response-helper');
module.exports.hello = async (event) => {
return createJsonResponse(
200,
{
message: 'Go Serverless v1.0! Your function executed successfully!',
input: event,
},
{
'X-Custom-Header': 'Foobar'
}
);
};