dotansimha / dotansimha/graphql-code-generator

Live examples bug: Opting out and back into `Client Preset` results in `syntax error`

Open
#9,546 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
11.3k
Forks
1.4k
Avg merge
1d 1h
Merged PRs (30d)
23

Description

### Describe the bug

On live examples, opting out and back into `Client Preset` result in `Syntax Error: Unexpected Name "import"`.

### Your Example Website or App

https://the-guild.dev/graphql/codegen

### Steps to Reproduce the Bug or Issue

1. Go to codegen homepage
2. select example other than Client Preset
3. reselect Client Preset
4. see generated output

### Expected behavior

example generation should work fine on every run :)

### Screenshots or Videos

[_No response_](https://github.com/dotansimha/graphql-code-generator/assets/56203151/11cb1315-04d1-42e6-91c7-2d1a96c2cf5b)

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.