gatsbyjs/gatsby-source-wordpress-experimental

WpMenu on Gatsby not returning any value while on GraphiQL returns

Closed this issue · 1 comments

Hello,

I'm trying to fetch the menus but on Gatsby GraphQL not getting any value while GraphiQL IDE on WordPress is working fine

GraphiQL
image

Gatsby GraphQL
image

Anyone can help me with this?

Hi there, this is because menus with no location set are private data in WP. Using wp-graphiql isn't an effective debugging tool for Gatsby because it's authenticated by default and Gatsby makes only unauthenticated requests. See https://github.com/gatsbyjs/gatsby-source-wordpress-experimental/blob/master/docs/using-data.md#menus for more info