graphql / graphql-playground

🎮 GraphQL IDE for better development workflows (GraphQL Subscriptions, interactive docs & collaboration)
MIT License
8.77k stars 735 forks source link

[Question] How does playground manage to print the SDL ordered semantically instead of alphabetically. (i.e Query type first, then types referred from that and so on..) #1266

Closed Ambro17 closed 4 years ago

Ambro17 commented 4 years ago

This issue pertains to the following package(s):

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

N/A

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

Not an issue

What is the expected behavior?

N/A

What is the actual behavior?

N/A

What steps may we take to reproduce the behavior?

Open playground Click on schema See that Query type is first, then the types referred there, and so on. The order is not alphabetical

Please provide a gif or image of the issue for a quicker response/fix.

acao commented 4 years ago

printSchema() in graphql-js determines this!

in the latest release, i removed any additional formatting, as graphql 15 does a fine job of formatting the printed output