Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Prettier version to allow 'interfaces to implement other interfaces' #1415

Open
1 of 7 tasks
joaohaas opened this issue Feb 6, 2023 · 1 comment
Open
1 of 7 tasks

Comments

@joaohaas
Copy link

joaohaas commented Feb 6, 2023

This issue pertains to the following package(s):

  • GraphQL Playground - Electron App
  • GraphQL Playground HTML
  • GraphQL Playground
  • GraphQL Playground Express Middleware
  • GraphQL Playground Hapi Middleware
  • GraphQL Playground Koa Middleware
  • GraphQL Playground Lambda Middleware

What OS and OS version are you experiencing the issue(s) on?

MacOS and Linux

What version of graphql-playground(-electron/-middleware) are you experiencing the issue(s) on?

Not really sure, it's from an internal forked version, but it should happen in all versions.

What is the expected behavior?

Given you have an interface that implements another interface (interface A implements B), the Schema tab should not break.

What is the actual behavior?

Currently trying to access the Schema tab on the side bar breaks the app. I managed to trace the issue to the prettify function in utils.ts, which in turn calls Prettier. Checking Prettier's changelog, this 'feature' was only implemented in version 2.1:
https://prettier.io/blog/2020/08/24/2.1.0.html#allow-interfaces-to-implement-other-interfaces-8007httpsgithubcomprettierprettierpull8007-by-fiskerhttpsgithubcomfisker

Changing the version to 2.1.2 fixed the issue for me, but maybe it could be upgraded further.

What steps may we take to reproduce the behavior?

Implement an interface to another interface and try to access the Schema tab on the sidel.

@joaohaas joaohaas changed the title Update Prettier version to support ' Update Prettier version to allow 'interfaces to implement other interfaces' Feb 6, 2023
@joaohaas
Copy link
Author

joaohaas commented Feb 6, 2023

Sorry for the edits, I think I ended up pressing some shortcut that posted the issue before I filled all the data.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant