hasura / hasura/graphql-engine
Custom GraphQL Root Fields editor and output order mismatch
- Dominant language
- TypeScript
- Stars
- 32.1k
- Forks
- 3k
- PR merge metrics
- PR metrics pending
Description
### Version Information
Server Version: 2.2.0
### Environment
OSS
### What is the expected behaviour?
I expect the Custom GraphQL Root Fields editor and viewer/metadata to be set in the same order.
### What is the current behaviour?
Editor goes queries [select, select_by_pk, select_aggregate] and mutations [insert, insert_one, update, update_by_pk, delete, delete_by_pk]
Viewer and metadata strangely goes: [insert, select_aggregate, insert_one, select_by_pk, select, delete, update, delete_by_pk, update_by_pk]
### How to reproduce the issue?
1. Track a table
2. Modify it
3. Open Custom GraphQL Root Fields
4. Fill all queries and mutations with custom names
5. Notice that the order is completely different from the editor
6. Export metadata
7. Notice that the order is completely different from the editor
### Screenshots or Screencast



This is especially annoying to me because when I only rename the mutations, the order is also a bit different from the editor, but nowhere near as bad:


Contributor guide
Assessment
This issue has not been assessed yet.