Closed walshe closed 5 years ago
This looks like a problem with the node version that serverless is executing under not knowing how to interpret your handler source. Could you provide some more details?
when I changed it to "module.exports.job = ".. it worked
would be nice for it to support newer versions of ecma script though
The plugin is not tied to any specific version of ecma script, it's just executing the node handler functions the same as lambda will. I suspect that you will want to look into using serverless-webpack if you want your lambdas to run with modern JS features.
does it have issue with es6/7 ?
`export const job = async (event, context, callback) => { ^^^^^^
SyntaxError: Unexpected token export at createScript (vm.js:80:10)`