This version of @urql/core
renames Operation.operationName
to Operation.kind
. For now the old
property is merely deprecated and will issue a warning if it's used directly. That said, all
exchanges that are released today also need this new version of @urql/core@>=1.14.0
, so if you
upgrade to any of the following packages, you will also need to upgrade @urql/core
. If you upgrade
and see the deprecation warning, check whether all following exchanges have been upgraded:
@urql/exchange-auth@0.1.2
@urql/exchange-execute@1.0.2
@urql/exchange-graphcache@3.1.8
@urql/exchange-multipart-fetch@0.1.10
@urql/exchange-persisted-fetch@1.2.2
@urql/exchange-populate@0.2.1
@urql/exchange-refocus@0.2.1
@urql/exchange-retry@0.1.9
@urql/exchange-suspense@1.9.2
Edit: Some of these packages have already been bumped by another patch version. Please just double check that you're bumping to the newest version, if possible.**
Once you've upgraded @urql/core
please also ensure that your package manager hasn't accidentally
duplicated the @urql/core
package. If you're using npm
you can do so by running npm dedupe
,
and if you use yarn
you can do so by running yarn-deduplicate
.
If you have a custom exchange, you can mute the deprecation warning by using Operation.kind
rather
than Operation.operationName
. If these exchanges are copying or altering operations by spreading
them this will also trigger the warning, which you can fix by using the new makeOperation
helper
function.
Minor Changes
- Deprecate the
Operation.operationName
property in favor ofOperation.kind
. This name was
previously confusing asoperationName
was effectively referring to two different things. You can
safely upgrade to this new version, however to mute all deprecation warnings you will have to
upgrade allurql
packages you use. If you have custom exchanges that spread operations, please
use the newmakeOperation
helper
function instead, by @bkonkle (See #1045)