message: support for apollo-server 2: expose typeDefs
diff: @@ -30,6 +30,7 @@ export class GraphQLApp {
  private _resolvedInitParams: { [key: string]: any; } = {};
  private _currentContext = null;
  private _allImplementations: { [key: string]: any; };
  + private _typeDefs: string;
  constructor(private options: GraphQLAppOptions) {
  this._modules = options.modules;
  @@ -40,12 +41,13 @@ export class GraphQLApp {
  const nonModules = this.options.nonModules || {};
  const mergedResolvers = mergeResolvers(this._modules.map(m => m.resolvers || {}).concat(nonModules.resolvers || {}));
  this._resolvers = this.composeResolvers(mergedResolvers, this.options.resolversComposition);
  -
  - this._schema = makeExecutableSchema({
  - typeDefs: mergeGraphQLSchemas([
  + this._typeDefs = mergeGraphQLSchemas([
  ...allTypes,
  ...(Array.isArray(nonModules.typeDefs) ? nonModules.typeDefs : nonModules.typeDefs ? [nonModules.typeDefs] : []),
  - ]),
  + ]);
  +
  + this._schema = makeExecutableSchema({
  + typeDefs: this._typeDefs,
  resolvers: this._resolvers,
  });
  }
  @@ -114,6 +116,10 @@ export class GraphQLApp {
  return this._resolvers;
  }
  + get typeDefs(): string {
  + return this._typeDefs;
  + }
  +
  private async buildImplementationsObject() {
  const relevantImplModules: GraphQLModule[] = this._modules.filter(f => f.implementation);
  const result = {};
  