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
[DRAFT] Schema type renaming #276
base: feature/rename-schema-types
Are you sure you want to change the base?
[DRAFT] Schema type renaming #276
Conversation
✅ Deploy Preview for eclectic-pie-88a2ba canceled.
|
Adding new IR types to represent schema types
Updated this draft with the initial pass at the new IR types to represent the schema types, all changes are under the |
apollo-ios-codegen/Sources/ApolloCodegenLib/ApolloCodegen.swift
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file should no longer be needed once this work is complete
@@ -0,0 +1,39 @@ | |||
import Foundation | |||
|
|||
public protocol NamedItem { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Open to different naming for this protocol.
Redid the new name handling to be on existing GraphQL schema type objects in GraphQLCompiler instead of new IR objects.
…e-types # Conflicts: # apollo-ios-codegen/Sources/ApolloCodegenLib/Templates/InterfaceTemplate.swift
@@ -224,6 +224,23 @@ class EntitySelectionTree { | |||
targetSelections.mergeIn(scopeSelections, from: source) | |||
} | |||
|
|||
if let conditionalScopes = scopeConditions { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure why these changes are here? Not related to the work I am doing
Have this updated with what should be the final implementation for handling schema type renaming after going through a few iterations. Moving on to implementing tests now and will see from there if any further tweaks are needed. |
This is a rough mvp of one of the approaches to handling custom schema type names to validate path forward before cleaning up code and adding tests etc.