DEV Community

Discussion on: How do You Structure Your Code When Moving Your API from Express to Serverless Functions?

Collapse
 
lambdafalcon profile image
falcon

A curiosity:
Why do you use let instead of const in the line:
let { req, res } = context;?

Collapse
 
john_papa profile image
John Papa

Hi - no reason. const is my preferred when no changes exist.

Collapse
 
lambdafalcon profile image
falcon

Alright, but then which changes do exist in this case?