Skip to content

Generating duplicate types on fragments #33

@xndyz

Description

@xndyz

Thank you for all the work on the v1 release! I'm experiencing duplicate types being generated when using this along with a plugin that has introspecting GraphQL like Contentful:

ERROR in /Users/fang/app/src/__generated__/gatsby-types.ts(10461,13):
10461:13 Duplicate identifier 'GatsbyContentfulSizes_withWebp_noBase64Fragment'.
    10459 | export type GatsbyContentfulSizes_withWebpFragment = Pick<ContentfulSizes, 'base64' | 'aspectRatio' | 'src' | 'srcSet' | 'srcWebp' | 'srcSetWebp' | 'sizes'>;
    10460 | 
  > 10461 | export type GatsbyContentfulSizes_withWebp_noBase64Fragment = Pick<ContentfulSizes, 'aspectRatio' | 'src' | 'srcSet' | 'srcWebp' | 'srcSetWebp' | 'sizes'>;
          |             ^
    10462 | 
    10463 | export type PagesQueryQueryVariables = {};
    10464 | 

failed Building development bundle - 50.337s

^ This is just one example, it's happening for all fragments. Is there a current workaround for this or will there need to be a fix? @cometkim

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions