Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support enhanced plugins object structure #222

Open
wants to merge 1 commit into
base: v1
Choose a base branch
from

Conversation

vkartaviy
Copy link

This plugin doesn't support enhanced plugins object throwing below error

TypeError: _.get(...).includes is not a function
    at ServerlessDynamodbLocal.hasAdditionalStacksPlugin (~/node_modules/serverless-dynamodb-local/index.js:249:51)

The serverless plugins section supports two kind of formats:

Array object:

plugins:
  - plugin1
  - plugin2

Enhanced plugins object:

plugins:
  localPath: './custom_serverless_plugins'
  modules:
    - plugin1
    - plugin2

This PR add support for both of them.

The serverless plugins section supports two kind of formats:

Array object:

```
plugins:
  - plugin1
  - plugin2
```

Enhanced plugins object:

```
plugins:
  localPath: './custom_serverless_plugins'
  modules:
    - plugin1
    - plugin2
```
Copy link
Collaborator

@AshanFernando AshanFernando left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @vkartaviy . I have approved the changes. Waiting for a second review and approval before merging. There is another PR for the same purpose, sent before this. Will you be able to review that and see it serves the same purpose. If so, I could go ahead with that one. #214

@vkartaviy
Copy link
Author

@AshanFernando parsePluginsObject was introduced in serverless v1.28.0 so my PR may have compatibility issues with older serverless releases.

@cyberwombat
Copy link

What's the status with this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants