On this page

@graphql-yoga/urql-exchange

Changelog for @graphql-yoga/urql-exchange: every release with its changes and the pull requests behind them.

6.0.0

Major Changes

  • #4574 79b0e8b Thanks @egoodwinx! - ### Breaking Changes

    • Node: minimum supported version is now Node 22. Node 18 and 20 are no longer supported. Future releases will only support Node >=22.
    • GraphQL: minimum supported version is now GraphQL 16. GraphQL 14 and 15 are no longer supported.
    • Request body parsing: Yoga now limits request bodies to 25,000,000 bytes by default. Enforcing this limit streams the body through a byte counter, making POST body parsing asynchronous even for an in-memory body. As a result, yoga.fetch() can return a Promise where it previously returned a synchronous Response, even when all resolvers and plugins are synchronous.

    Migration

    • If you’re on Node 18/20, upgrade to Node 22 or later before upgrading this package.
    • If you’re on graphql 14/15, upgrade to graphql 16 or 17 first.
    • Await yoga.fetch() and response body parsing instead of relying on synchronous results. Set maxRequestBodySize: false in createYoga to disable the body-size limit and preserve synchronous parsing for in-memory bodies, but only if you enforce an appropriate request-body limit elsewhere.
  • #4623 be89d05 Thanks @ardatan! - ### Dependencies

    • Bump @graphql-tools/utils to ^13.1.1, @graphql-tools/schema to ^11.0.0, and @graphql-tools/executor to ^4.1.2.

    Incremental delivery

    Yoga maps the GraphQL HTTP Accept header through INCREMENTAL_DELIVERY_SPECS from @graphql-tools/utils onto executor incrementalSpec. multipart/mixed;incrementalSpec=v0.2 runs the v0.2 payload format and echoes that spec on Content-Type. multipart/mixed;deferSpec=20220824 or bare multipart/mixed stays on v0.1. An unsupported incremental spec yields 406.

    A later incremental spec is a graphql-tools table row plus an executor publisher. Yoga, Hive Gateway, and HTTP executors pick it up by bumping @graphql-tools/utils / @graphql-tools/executor.

    Breaking Changes

    • createGraphQLError is removed. Use new GraphQLError(message, options) from graphql. To attach Yoga’s experimental schema coordinate, use withSchemaCoordinate(error, coordinate) and read with getSchemaCoordinate from @graphql-tools/utils.
    • mapMaybePromise is removed (was exported from Yoga / @envelop/core). Use handleMaybePromise from @whatwg-node/promise-helpers.
    • Yoga no longer re-exports helpers that already live upstream:
      • getSchemaCoordinate -> @graphql-tools/utils
      • mergeSchemas -> @graphql-tools/schema
      • DisposableSymbols -> @whatwg-node/server
      • mapAsyncIterator / isPromise / fakePromise / handleMaybePromise / MaybePromise -> @whatwg-node/promise-helpers
    • @envelop/core utils no longer re-exports mapAsyncIterator or isPromise. Import from @whatwg-node/promise-helpers.
    • Use asGetArgumentValuesVariables / coerceGetVariableValuesResult from @graphql-tools/utils for GraphQL 16/17 VariableValues compatibility.

    Migration

    import { GraphQLError } from 'graphql'
    import { withSchemaCoordinate } from 'graphql-yoga'
    import { mergeSchemas } from '@graphql-tools/schema'
    import { getSchemaCoordinate } from '@graphql-tools/utils'
    import { handleMaybePromise, isPromise, type MaybePromise } from '@whatwg-node/promise-helpers'
    import { DisposableSymbols } from '@whatwg-node/server'
    
    throw withSchemaCoordinate(new GraphQLError('not found'), 'Query.user')

5.9.6

5.9.5

5.9.4

5.9.3

Patch Changes

5.9.2

5.9.1

5.9.0

Patch Changes

5.8.0

5.7.0

Minor Changes

  • #4545 94ebe5b Thanks @egoodwinx! - Update to support graphql-js 17

    Bump package versions, fix expected typing, and update compatability with subscribe.

5.6.3

5.6.2

5.6.1

5.6.0

5.5.0

5.4.0

5.3.1

5.3.0

5.2.1

5.2.0

5.1.2

5.1.1

5.1.0

5.0.0

Major Changes

Patch Changes

4.2.1

4.2.0

4.1.0

4.0.0

Major Changes

3.13.4

3.13.3

3.13.2

3.13.1

3.13.0

3.12.2

3.12.1

3.12.0

3.11.0

3.10.11

3.10.10

Patch Changes

3.10.9

3.10.8

3.10.7

3.10.6

3.10.5

3.10.4

3.10.3

Patch Changes

3.10.2

3.10.1

3.10.0

3.9.0

3.8.0

3.7.0

3.6.3

3.6.2

3.6.1

Patch Changes

3.6.0

3.5.0

3.4.0

3.3.1

3.3.0

3.2.0

3.1.1

3.1.0

3.0.3

3.0.2

3.0.1

Patch Changes

3.0.0

Major Changes

2.0.5

2.0.4

2.0.3

2.0.2

2.0.1

2.0.0

Major Changes

1.8.1

Patch Changes

1.8.0

1.7.1

Patch Changes

1.7.0

1.6.3

1.6.2

1.6.1

1.6.0

1.5.1

1.5.0

Patch Changes

1.4.1

Patch Changes

1.4.0

1.3.1

1.3.0

Patch Changes

1.2.1

1.2.0

Patch Changes

1.1.1

1.1.0

Patch Changes

1.0.1

Patch Changes

1.0.0

Major Changes

Patch Changes

1.0.0-next.1

Patch Changes

1.0.0-next.0

Major Changes