This repository has been archived by the owner on Feb 9, 2023. It is now read-only.
generated from apollographql/typescript-repo-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: return an request handler instead of Response
BREAKING CHANGE: - Before: const response = startServerAndCreateCloudflareHandler(server, { cors: { // cors configuration }, context: async () => { const cache = options.kvCache ? new KVCache() : server.cache; const dataSources: ApolloDataSources = { pokemonAPI: new PokemonAPI({ cache }), }; return { dataSources }; } }); - After: const handleGraphQLRequest = startServerAndCreateCloudflareHandler(server, { cors: options.cors, context: async () => { const cache = options.kvCache ? new KVCache() : server.cache; const dataSources: ApolloDataSources = { pokemonAPI: new PokemonAPI({ cache }), }; return { dataSources }; } }); const response = await handleGraphQLRequest(request);
- Loading branch information
Showing
4 changed files
with
76 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters