@sanity/client 6.6.0 → 6.7.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/README.md +1 -1
- package/dist/index.browser.cjs +3 -2
- package/dist/index.browser.cjs.map +1 -1
- package/dist/index.browser.js +3 -2
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cjs +4 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/data/dataMethods.ts +3 -2
- package/src/types.ts +1 -1
- package/umd/sanityClient.js +3 -2
- package/umd/sanityClient.min.js +1 -1
package/README.md
CHANGED
|
@@ -1092,7 +1092,7 @@ client.delete('image-abc123_someAssetId-500x500-png').then((result) => {
|
|
|
1092
1092
|
|
|
1093
1093
|
### Mutation options
|
|
1094
1094
|
|
|
1095
|
-
The following options are available for mutations, and can be applied either as the second argument to `create()`, `createOrReplace`, `
|
|
1095
|
+
The following options are available for mutations, and can be applied either as the second argument to `create()`, `createOrReplace`, `createIfNotExists`, `delete()` and `mutate()` - or as an argument to the `commit()` method on patches and transactions.
|
|
1096
1096
|
|
|
1097
1097
|
- `visibility` (`'sync'|'async'|'deferred'`) - default `'sync'`
|
|
1098
1098
|
- `sync`: request will not return until the requested changes are visible to subsequent queries.
|
package/dist/index.browser.cjs
CHANGED
|
@@ -972,9 +972,10 @@ function _requestObservable(client, httpRequest, options) {
|
|
|
972
972
|
};
|
|
973
973
|
}
|
|
974
974
|
if (["GET", "HEAD", "POST"].indexOf(options.method || "GET") >= 0 && uri.indexOf("/data/query/") === 0) {
|
|
975
|
-
|
|
975
|
+
const resultSourceMap = (_a = options.resultSourceMap) != null ? _a : config.resultSourceMap;
|
|
976
|
+
if (resultSourceMap !== void 0 && resultSourceMap !== false) {
|
|
976
977
|
options.query = {
|
|
977
|
-
resultSourceMap
|
|
978
|
+
resultSourceMap,
|
|
978
979
|
...options.query
|
|
979
980
|
};
|
|
980
981
|
}
|