Steps to set up serverless offline
The first step is to include the serverless-offline Node.js package in your existing application. To set up serverless offline in your project, run the following command in your Node.js project.
Once the package is installed, add the following in the plugin section of your serverless.yml file. Add the plugin section if you don’t already have it.
Save the file and verify that the package is installed by running the following command from your terminal.
This will start a local server that emulates AWS Lambda and API gateways on your local machine.