DEV Community


Serverless Framework Template

Subhankar De
I am a well-rounded software engineer, almost two decades in the industry. Cloud enthusiast, love building serverless and cloud agonistic solutions.
Updated on ・1 min read

Serverless Framework Template - ES6/ES7 Compatible

This Github project template will standardize

  • Consistent src folder structure across multiple projects.
  • serverless-bundle plugin: Optimally packages your ES6 or TypeScript Node.js Lambda functions with sensible defaults so you don't have to maintain your own Webpack configs.
  • serverless-pseudo-parameters plugin: Allows you to take advantage of CloudFormation Pseudo Parameters.

Getting started

sls create --name <YOUR_PROJECT_NAME> --template-url
npm install
Enter fullscreen mode Exit fullscreen mode

The latest version of Webpack is not compatible. Please use the below version. Please be aware that AWS-SDK is in the DEV dependencies. Please move it to dependencies for PROD. AWS Lambda will use the latest SDK for the current template.

Latest npm packages

npm i -g npm-check-updates
ncu -u
npm install
Enter fullscreen mode Exit fullscreen mode

Webpack version

npm uninstall webpack
npm install --save-dev webpack@4.46.0
Enter fullscreen mode Exit fullscreen mode

VS Code command for Mac

code .
Enter fullscreen mode Exit fullscreen mode

Top serverless plugins

  • serverless-offline
  • serverless-step-functions
  • serverless-plugin-canary-deployments
  • serverless-dynamodb-local

Discussion (0)