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

Docs not up to date #588

Open
mstoyanovv opened this issue Mar 31, 2023 · 2 comments
Open

Docs not up to date #588

mstoyanovv opened this issue Mar 31, 2023 · 2 comments

Comments

@mstoyanovv
Copy link

The documentation here is about version 1 of this plugin which is not stated and leads to erros because 'appSync' is no longer under 'custom' in the yaml file. 'npm install serverless-appsync-plugin' would install v2 therefore the whole page is irrelevant.

The 'up to date' examples in the repo here like the 'quick start' one:

service: my-app

plugins:
  - serverless-appsync-plugin

provider:
  name: aws

appSync:
  name: my-api

  authentication:
    type: API_KEY

  apiKeys:
    - name: myKey
      expiresAfter: 1M

  dataSources:
    my-table:
      type: AMAZON_DYNAMODB
      description: 'My table'
      config:
        tableName: my-table

  resolvers:
    Query.user:
      dataSource: my-table

is failing with "Cannot read properties of undefined (reading 'map')". Looks like the plugin is searching for functions property in a resolver.

@bboure
Copy link
Collaborator

bboure commented Mar 31, 2023

Thanks @mstoyanovv
Unfortunately I cannot change the serverless article.

The issue you point out seems like a bug. If not provided, functions should probably just be an empty array, or we should skip some parts of the code that builds functions.

I'll have a look asap

@KristofferBerg
Copy link

Thanks for addressing this issue! I got stuck for so long! Someone should update the serverless.com article :/

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

No branches or pull requests

3 participants