static-dev/spike-contentful

Throws an error when setting the limit past 100

Closed this issue · 1 comments

Trying to add this content type in the settings:

new Contentful({
  addDataTo: locals,
  accessToken: 'xxx',
  spaceId: 'xxx',
  contentTypes: [{
    name: 'blogs',
    id: 'blogPost'
    filters: {
      order: '-fields.date',
      limit: 1000
    }
  }]
})

Throws this error:

Error: ValidationError: [spike-contentful constructor] option "contentTypes" at position 1 fails because [spike-contentful constructor] option [spike-contentful constructor] option "limit" must be less than or equal to 100

Since the Contentful API allows for up to 1000 entries (link), is there a reason this plugin limits it to 100?

Aaaand I see this was literally just fixed: #90