These are examples of what we’ve seen in the wild. Feel free and try other options and share them with us!
Model Bound Queries
Queries extend Swift model as static constants.We usually start the project by creating a
GraphQL folder in the root folder of our project. Then, we generate the API.swift file inside GraphQL folder and add Scalars, Query, Mutation and Subscription folders if needed. To prevent any naming collisions we create custom queries in files that follow the pattern of <structure><action> (e.g. HumanQuery.swift or HumanSubscription.swift).
This leaves us with a tree structure resembling
- GraphQL
- API.swift
 - Scalars
- DateTime.swift
 - URL.swift
 
 - Query
- HumanQuery.swift
 - CharacterQuery.swift
 
 - Mutation
- AuthMutation.swift
 
 - Subscription
- TimeSubscription.swift
 
 
 
- “regular mappings” use 
selectionvariable, and - methods on root types (i.e. 
query,mutationandsubscription) should be calledqueryandmutationandsubscriptionrespectively. 
View Bound Queries
Queries extend SwiftUI views as static variables.Each SwiftUI component that relies on GraphQL data exports a query as a static value that can be used to obtain the data. Parent components then hoist selections from their children and create a query request to the server.