gatsby-source-strapi icon indicating copy to clipboard operation
gatsby-source-strapi copied to clipboard

Gatsby build failing if no content has been creates

Open vimtor opened this issue 5 years ago • 4 comments

Perhaps this is the intended behavior since I am not familiar with GraphQL, but when querying all the content using allStrapi* the build crashes instead of returning an empty array.

It's not super important but I figured out that it should be easy to fix.

vimtor avatar Jan 06 '20 18:01 vimtor

Related issues: https://github.com/strapi/gatsby-source-strapi/issues/86#issuecomment-566526300 https://github.com/strapi/gatsby-source-strapi/issues/94#issuecomment-570039297

henrych4 avatar Jan 10 '20 02:01 henrych4

I have the same problem. How can it be fixed if it's easy to fix?

Borisboky avatar Jan 31 '20 06:01 Borisboky

I simply added some dummy data

vimtor avatar Jan 31 '20 08:01 vimtor

Thanks, but that is not ideal because I have 80 content types and more than 1000 fields (there are also images). Thus if I in some case use only 50 fields, I need to add some dummy data to all of them. That is too much.

Borisboky avatar Jan 31 '20 08:01 Borisboky

Thanks for your interest in this project. This plugin is moving into the Gatsby User Collective and this repo will be archived. Please open an issue in that repository, submit a PR if you'd like to see this implemented, or join us on Discord if you have questions!

moonmeister avatar Dec 27 '22 18:12 moonmeister