@graphcommerce/graphql-mesh 4.1.9 → 4.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Change Log
2
2
 
3
+ ## 4.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#1633](https://github.com/graphcommerce-org/graphcommerce/pull/1633) [`4487db309`](https://github.com/graphcommerce-org/graphcommerce/commit/4487db309df01a22f49876cf4a5574ece303a8ca) Thanks [@timhofman](https://github.com/timhofman)! - Send gcms-locales header to the Hypgraph backend so requests are translated.
8
+
3
9
  ## 4.1.9
4
10
 
5
11
  ### Patch Changes
@@ -1,6 +1,7 @@
1
1
  /* eslint-disable react-hooks/rules-of-hooks */
2
2
  import { useApolloTracing } from '@envelop/apollo-tracing'
3
3
  import { createServer as createYogaServer } from '@graphql-yoga/node'
4
+ import { NextApiRequest, NextApiResponse } from 'next'
4
5
  import { getBuiltMesh, rawServeConfig } from '../.mesh'
5
6
 
6
7
  export async function createServer(endpoint: string) {
@@ -10,7 +11,10 @@ export async function createServer(endpoint: string) {
10
11
  const { cors, playgroundTitle } = rawServeConfig ?? {}
11
12
 
12
13
  // pass the Mesh instance to Yoga and configure GraphiQL
13
- const server = createYogaServer({
14
+ return createYogaServer<{
15
+ req: NextApiRequest
16
+ res: NextApiResponse
17
+ }>({
14
18
  plugins: [...mesh.plugins, useApolloTracing()],
15
19
  context: ({ req }) => ({ ...req, ...mesh.meshContext }),
16
20
  graphiql: {
@@ -23,6 +27,4 @@ export async function createServer(endpoint: string) {
23
27
  logging: mesh.logger,
24
28
  cors,
25
29
  })
26
-
27
- return server.requestListener
28
30
  }
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@graphcommerce/graphql-mesh",
3
3
  "homepage": "https://www.graphcommerce.org/",
4
4
  "repository": "github:graphcommerce-org/graphcommerce",
5
- "version": "4.1.9",
5
+ "version": "4.2.0",
6
6
  "author": "",
7
7
  "license": "MIT",
8
8
  "main": "index.ts",
@@ -11,6 +11,7 @@
11
11
  "@graphql-mesh/apollo-link": "^6.0.0",
12
12
  "@graphql-mesh/config": "6.2.0",
13
13
  "@graphql-mesh/graphql": "0.30.0",
14
+ "@graphql-mesh/transform-filter-schema": "0.14.87",
14
15
  "@graphql-mesh/types": "0.80.2",
15
16
  "@graphql-mesh/utils": "0.40.0",
16
17
  "@graphql-yoga/node": "^2.13.11",