Skip to content

Incorrect type generation #3

Description

@nikivdev

CleanShot 2023-10-11 at 22 17 46@2x

Image shows it well.

My schema is:

export const typeDefs = `
"""
De-prioritizes a fragment, causing the fragment to be omitted in the initial response and delivered as a subsequent response afterward.
"""
directive @defer(
  """When true fragment may be deferred"""
  if: Boolean! = true

  """
  This label should be used by GraphQL clients to identify the data from patch responses and associate it with the correct fragment.
  """
  label: String
) on INLINE_FRAGMENT | FRAGMENT_SPREAD

"""Directs the executor to return values as a Streaming response."""
directive @live on QUERY

"""Indicates that an input object is a oneOf input object"""
directive @oneOf on INPUT_OBJECT

type GlobalLink {
  id: String!
  title: String!
  url: String!
  year: String
}

type Mutation {
  createUser(email: String!): String!
  updateLatestGlobalGuide(topicSummary: String!, sections: [section!]!): String!
}

type Query {
  publicGetGlobalTopics: [publicGetGlobalTopicsOutput!]!
  publicGetGlobalTopic(topicName: String!): publicGetGlobalTopicOutput!
  getGlobalLink(linkId: String!): publicGetGlobalLinkOutput!
  getGlobalLinks: getGlobalLinksOutput!
  checkForGlobalLink(linkUrl: String!): publicCheckForGlobalLinkOutput!
  stripe(plan: String!): String!
}

type getGlobalLinksOutput {
  id: String!
  title: String!
  url: String!
}

type globalGuideSection {
  title: String!
  links: [GlobalLink!]!
}

type latestGlobalGuide {
  summary: String!
  sections: [globalGuideSection!]!
}

type publicCheckForGlobalLinkOutput {
  url: String!
  title: String!
  year: Int
  description: String
}

type publicGetGlobalLinkOutput {
  title: String!
  url: String!
  verified: Boolean!
  public: Boolean!
  protocol: String
  fullUrl: String
  description: String
  urlTitle: String
  year: String
}

type publicGetGlobalTopicOutput {
  prettyName: String!
  topicSummary: String!
  topicPath: String
  latestGlobalGuide: latestGlobalGuide
  links: [GlobalLink!]!
}

type publicGetGlobalTopicsOutput {
  prettyName: String!
  name: String!
}

input section {
  title: String!
  summary: String
  linkIds: [String!]!
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions