-
-
Notifications
You must be signed in to change notification settings - Fork 458
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(core) - Deprecate the "operationName" property and move to "kind" (#…
…1045) * Deprecate the Operation.operationName property in core/src/client * Add some missing files * Update the core exchanges * Add a changeset * Update the multipart-fetch exchange * Update the persisted-fetch exchange * Update exchanges and move getOperationName to utils * Remove confusing destructuring * Update the changeset * Update the testing doc * Update a reference to getOperationName * Update a reference to makeOperation * Make client.createOperationContext public * Changes for PR feedback * Update makeOperation and move addMetadata The addMetadata utility was definitely kept in the wrong place since it concerns operations. `makeOperation` has been updated to fill out the context if it isn't passed which may become convenient in a couple of places, instead setting it to the `operation.context`. * Update operation spreads to use `makeOperation` * Fix additional operation mapping case in cacheExchange * Update core docs and add callout to changeset * Replace all remaining operation spreads with makeOperation Co-authored-by: Phil Pluckthun <phil@kitten.sh>
- Loading branch information
Showing
51 changed files
with
841 additions
and
635 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
'@urql/exchange-auth': patch | ||
'@urql/exchange-execute': patch | ||
'@urql/exchange-graphcache': patch | ||
'@urql/exchange-multipart-fetch': patch | ||
'@urql/exchange-persisted-fetch': patch | ||
'@urql/exchange-populate': patch | ||
'@urql/exchange-refocus': patch | ||
'@urql/exchange-retry': patch | ||
'@urql/exchange-suspense': patch | ||
'@urql/core': minor | ||
'urql': patch | ||
--- | ||
|
||
Deprecate the `Operation.operationName` property in favor of `Operation.kind`. This name was | ||
previously confusing as `operationName` 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** all `urql` packages you use. If you have custom exchanges that spread operations, please | ||
use [the new `makeOperation` helper | ||
function](https://formidable.com/open-source/urql/docs/api/core/#makeoperation) instead. |
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
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
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
Oops, something went wrong.