1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | 1x 1x 1x 1x 1x | 'use strict'; const HelloWorld = require('./lib/hello-world'); module.exports.helloWorld = (event, context, callback) => { var hlloWorld = new HelloWorld(); const response = { statusCode: 200, headers: { 'Access-Control-Allow-Origin': '*', // Required for CORS support to work }, body: JSON.stringify(hlloWorld.sayHello(event)), }; callback(null, response); }; |