elm-pages-v3-beta/examples/docs/functions/time.js

15 lines
327 B
JavaScript
Raw Normal View History

2021-04-29 17:27:19 +03:00
exports.handler =
/**
* @param {import('aws-lambda').APIGatewayProxyEvent} event
* @param {any} context
*/
async function (event, context) {
return {
body: JSON.stringify(new Date().toTimeString()),
headers: {
"Content-Type": "application/json",
},
statusCode: 200,
};
};