See #2059.
The part about "make it Just Work™ with any extension" is that ApolloCodegenConfiguration has separate FileInput properties for schema and operations. These could conceivably have any extension since the content is loaded and fed into the JS frontend. For that to work though ApolloCodegen.compileResults(using:) would need to change to use loadSchemaFromSDL or loadSchemaFromIntrospectionResult instead of loadSchema which looks at the extension for a hint on how to handle the file.