Skip to content

Commit 7575f51

Browse files
committed
feat(lambda): expose additional yoga v1.0 options in lambda handler
Closes #81
1 parent cb9bd3d commit 7575f51

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

Diff for: src/lambda.ts

+9
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,15 @@ export class GraphQLServerLambda {
8383
schema: this.executableSchema,
8484
tracing: tracing(event),
8585
context: apolloContext,
86+
cacheControl: this.options.cacheControl,
87+
formatError: this.options.formatError,
88+
logFunction: this.options.logFunction,
89+
rootValue: this.options.rootValue,
90+
validationRules: this.options.validationRules,
91+
fieldResolver: this.options.fieldResolver,
92+
formatParams: this.options.formatParams,
93+
formatResponse: this.options.formatResponse,
94+
debug: this.options.debug,
8695
}
8796
})
8897
return handler(event, context, callbackFilter)

Diff for: src/types.ts

+1-3
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,6 @@ export interface LambdaProps {
8282
options?: LambdaOptions
8383
}
8484

85-
export interface LambdaOptions {
86-
tracing?: boolean | TracingOptions
87-
uploads?: UploadOptions
85+
export interface LambdaOptions extends ApolloServerOptions {
8886
endpoint?: string
8987
}

0 commit comments

Comments
 (0)