skip to Main Content

The fields that are available in Strapi don’t appear in GraphQL schema (GraphiQL playground)Strapi component structure
Strapi structure

I tried everything:

  1. all permissions are given in the Roles;
  2. deep population works, gatsby-source-strapi is configured (except for dynamic zones (for my sections’ components) that I haven’t even seen how to populate;
  3. reconnecting my CMS to another (it’s not even reconnected to another app – I see a starter GraphQL schema all the time);
  4. Installed deep-populate Strapi plugin;
    Anybody faced such a problem ???
    P.S. I have a self-hosted Strapi CMS.

2

Answers


  1. Chosen as BEST ANSWER

    Here's how I solved a situation in my gatsby-config:

    {
                singularName: "page",
                queryParams: {
                  populate: {
                    sections: {
                      populate: [
                        "list.image",
                        "list.page",
                        "list.thumbnail",
                        "cta",
                        "images",
                        "image",
                      ],
                    },
                  },
                },
              },` 
    

  2. This gatsby-source-strapi plugin only take 2 level not take multi level. so we need to mention in the gatsby-config.js gatsby-source-strapi plugin config like below.

            {
            singularName: 'partner',
            queryParams: {
              populate: {
                'list': {
                  populate: {                   
                    'image':{
                      populate: "*"
                    },
                  }
                }
         }
    

    I think this will help you.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search