Skip to content

Commit da5fb7c

Browse files
authored
Create README.md
This is part off this change in serverless-webpack: #131 Explain how to work with the serverless-offline, serverless-webpack and serverless-dynamodb-local
1 parent fa63795 commit da5fb7c

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,18 @@ Options are:
171171
- `--function` or `-f` (required) is the name of the function to run
172172
- `--path` or `-p` (optional) is a JSON file path used as the function input event
173173

174+
### Using with serverless-offline and serverless-webpack plugin
175+
176+
Run `serverless offline start`. In comparison with `serverless offline`, the `start` command will fire an `init` and a `end` lifecycle hook which is needed for serverless-offline and serverless-dynamodb-local to switch off both ressources.
177+
178+
Add plugins to your `serverless.yml` file:
179+
```yaml
180+
plugins:
181+
- serverless-webpack
182+
- serverless-dynamodb-local
183+
- serverless-offline #serverless-offline needs to be last in the list
184+
```
185+
174186
### Bundle with webpack
175187
176188
To just bundle and see the output result use:

0 commit comments

Comments
 (0)