why `GraphQl` is not being update?

13 Views Asked by At

currently i m working with vue storefront that is being use magento2 as backend and as cms also here i added images to top categories of app like men ,women but its not displaying i checked gql query that is responsible of getting categories from db image was missing there i added it there but its not being update dont know why here is my code base:

const fragmentCategory = `
  fragment CategoryFields on CategoryTree {
    is_anchor
    name
    position
    product_count
    uid
    url_path
    url_suffix
    image
  }
`;

export default `
  query categoryList {
    categories {
      items {
        ...CategoryFields
        children {
          ...CategoryFields
          children {
            ...CategoryFields
            children {
              ...CategoryFields
            }
          }
        }
      }
    }
  }
  ${fragmentCategory}
`;

its displaying every thing except images i also changed its interfaces but nothing happend, here is interface code:

export declare type CategoryListQuery = {
  categories?: {
    items?: Array<{
      product_count?: number | null | undefined;
      name?: string | null | undefined;
      uid: string;
      children?: Array<{
        include_in_menu?: number | null | undefined;
        is_anchor?: number | null | undefined;
        level?: number | null | undefined;
        name?: string | null | undefined;
        position?: number | null | undefined;
        product_count?: number | null | undefined;
        uid: string;
        url_path?: string | null | undefined;
        url_suffix?: string | null | undefined;
        image?: string;
        children?: Array<{
          include_in_menu?: number | null | undefined;
          is_anchor?: number | null | undefined;
          level?: number | null | undefined;
          name?: string | null | undefined;
          position?: number | null | undefined;
          product_count?: number | null | undefined;
          uid: string;
          url_path?: string | null | undefined;
          url_suffix?: string | null | undefined;
          image?: string ;
          children?: Array<{
            include_in_menu?: number | null | undefined;
            is_anchor?: number | null | undefined;
            level?: number | null | undefined;
            name?: string | null | undefined;
            position?: number | null | undefined;
            product_count?: number | null | undefined;
            uid: string;
            url_path?: string | null | undefined;
            url_suffix?: string | null | undefined;
            image?: string;
          } | null | undefined> | null | undefined;
        } | null | undefined> | null | undefined;
      } | null | undefined> | null | undefined;
    } | null | undefined> | null | undefined;
  } | null | undefined;
};

tell what i can to achieve my requirement??

0

There are 0 best solutions below