gatsby-source-sanity
gatsby-source-sanity copied to clipboard
Detect and warn on data already in gatsby image format
A scenario that came up in our community slack:
User requests gatsby image data from GraphQL, but due to a misunderstanding passes this data to the getGatsbyImageData()
method. It crashes because of an invalid expectation on what the input looks like.
It looks like we:
a) Need more input validation on the getGatsbyImageData()
method
b) Could detect if already in the right format and throw/warn about the incorrect usage