@kwiz/common 1.0.212 → 1.0.213
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.
|
@@ -4,9 +4,11 @@ exports.AllRestCacheOptionsKeys = exports.contentTypes = exports.jsonTypes = voi
|
|
|
4
4
|
// eslint-disable-next-line no-shadow
|
|
5
5
|
var jsonTypes;
|
|
6
6
|
(function (jsonTypes) {
|
|
7
|
-
jsonTypes["verbose"] = "application/json;
|
|
8
|
-
jsonTypes["minimal"] = "application/json;
|
|
9
|
-
jsonTypes["nometadata"] = "application/json;
|
|
7
|
+
jsonTypes["verbose"] = "application/json;odata=verbose";
|
|
8
|
+
jsonTypes["minimal"] = "application/json;odata=minimal";
|
|
9
|
+
jsonTypes["nometadata"] = "application/json;odata=nometadata";
|
|
10
|
+
jsonTypes["minimalV4"] = "application/json;odata.metadata=minimal";
|
|
11
|
+
jsonTypes["noMetadataV4"] = "application/json;odata.metadata=none";
|
|
10
12
|
jsonTypes["standard"] = "application/json";
|
|
11
13
|
})(jsonTypes || (exports.jsonTypes = jsonTypes = {}));
|
|
12
14
|
// eslint-disable-next-line no-shadow
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rest.types.js","sourceRoot":"","sources":["../../../src/types/rest.types.ts"],"names":[],"mappings":";;;AAGA,qCAAqC;AACrC,IAAY,
|
|
1
|
+
{"version":3,"file":"rest.types.js","sourceRoot":"","sources":["../../../src/types/rest.types.ts"],"names":[],"mappings":";;;AAGA,qCAAqC;AACrC,IAAY,SASX;AATD,WAAY,SAAS;IACjB,uDAA0C,CAAA;IAC1C,uDAA0C,CAAA;IAC1C,6DAAgD,CAAA;IAEhD,kEAAqD,CAAA;IACrD,kEAAqD,CAAA;IAErD,0CAA6B,CAAA;AACjC,CAAC,EATW,SAAS,yBAAT,SAAS,QASpB;AAED,qCAAqC;AACrC,IAAY,YAGX;AAHD,WAAY,YAAY;IACpB,uCAAuB,CAAA;IACvB,yCAAyB,CAAA;AAC7B,CAAC,EAHW,YAAY,4BAAZ,YAAY,QAGvB;AAEY,QAAA,uBAAuB,GAAgC;IAChE,UAAU,EAAE,IAAI;IAChB,gBAAgB,EAAE,IAAI;IACtB,sBAAsB,EAAE,CAAC;IACzB,MAAM,EAAE,CAAC;CACZ,CAAC"}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
// eslint-disable-next-line no-shadow
|
|
2
2
|
export var jsonTypes;
|
|
3
3
|
(function (jsonTypes) {
|
|
4
|
-
jsonTypes["verbose"] = "application/json;
|
|
5
|
-
jsonTypes["minimal"] = "application/json;
|
|
6
|
-
jsonTypes["nometadata"] = "application/json;
|
|
4
|
+
jsonTypes["verbose"] = "application/json;odata=verbose";
|
|
5
|
+
jsonTypes["minimal"] = "application/json;odata=minimal";
|
|
6
|
+
jsonTypes["nometadata"] = "application/json;odata=nometadata";
|
|
7
|
+
jsonTypes["minimalV4"] = "application/json;odata.metadata=minimal";
|
|
8
|
+
jsonTypes["noMetadataV4"] = "application/json;odata.metadata=none";
|
|
7
9
|
jsonTypes["standard"] = "application/json";
|
|
8
10
|
})(jsonTypes || (jsonTypes = {}));
|
|
9
11
|
// eslint-disable-next-line no-shadow
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rest.types.js","sourceRoot":"","sources":["../../../src/types/rest.types.ts"],"names":[],"mappings":"AAGA,qCAAqC;AACrC,MAAM,CAAN,IAAY,
|
|
1
|
+
{"version":3,"file":"rest.types.js","sourceRoot":"","sources":["../../../src/types/rest.types.ts"],"names":[],"mappings":"AAGA,qCAAqC;AACrC,MAAM,CAAN,IAAY,SASX;AATD,WAAY,SAAS;IACjB,uDAA0C,CAAA;IAC1C,uDAA0C,CAAA;IAC1C,6DAAgD,CAAA;IAEhD,kEAAqD,CAAA;IACrD,kEAAqD,CAAA;IAErD,0CAA6B,CAAA;AACjC,CAAC,EATW,SAAS,KAAT,SAAS,QASpB;AAED,qCAAqC;AACrC,MAAM,CAAN,IAAY,YAGX;AAHD,WAAY,YAAY;IACpB,uCAAuB,CAAA;IACvB,yCAAyB,CAAA;AAC7B,CAAC,EAHW,YAAY,KAAZ,YAAY,QAGvB;AAED,MAAM,CAAC,MAAM,uBAAuB,GAAgC;IAChE,UAAU,EAAE,IAAI;IAChB,gBAAgB,EAAE,IAAI;IACtB,sBAAsB,EAAE,CAAC;IACzB,MAAM,EAAE,CAAC;CACZ,CAAC"}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { ILocalStorageCacheLifetime } from "./localstoragecache.types";
|
|
2
2
|
export type IRestResponseType = "" | "blob" | "arraybuffer" | "text" | "json" | "document";
|
|
3
3
|
export declare enum jsonTypes {
|
|
4
|
-
verbose = "application/json;
|
|
5
|
-
minimal = "application/json;
|
|
6
|
-
nometadata = "application/json;
|
|
4
|
+
verbose = "application/json;odata=verbose",
|
|
5
|
+
minimal = "application/json;odata=minimal",
|
|
6
|
+
nometadata = "application/json;odata=nometadata",
|
|
7
|
+
minimalV4 = "application/json;odata.metadata=minimal",
|
|
8
|
+
noMetadataV4 = "application/json;odata.metadata=none",
|
|
7
9
|
standard = "application/json"
|
|
8
10
|
}
|
|
9
11
|
export declare enum contentTypes {
|
|
@@ -21,12 +23,24 @@ export interface IRestCacheOptions {
|
|
|
21
23
|
forceCacheUpdate?: boolean;
|
|
22
24
|
}
|
|
23
25
|
export interface IRestRequestOptions {
|
|
24
|
-
/**
|
|
25
|
-
|
|
26
|
+
/**
|
|
27
|
+
* Request method.
|
|
28
|
+
*
|
|
29
|
+
* SharePoint typically uses `GET` or `POST`.
|
|
30
|
+
* For SharePoint updates/deletes, use `POST` with `xHttpMethod`.
|
|
31
|
+
*
|
|
32
|
+
* Microsoft Graph uses the actual HTTP method directly.
|
|
33
|
+
*/
|
|
34
|
+
method?: "GET" | "POST" | "MERGE" | "DELETE" | "PUT";
|
|
35
|
+
/**
|
|
36
|
+
* SharePoint-only method override.
|
|
37
|
+
* Used with `method: "POST"` for `MERGE`, `DELETE`, or `PUT`.
|
|
38
|
+
* Not used for Microsoft Graph.
|
|
39
|
+
*/
|
|
26
40
|
xHttpMethod?: "MERGE" | "DELETE" | "PUT";
|
|
27
|
-
/**default true */
|
|
41
|
+
/** default true */
|
|
28
42
|
includeDigestInPost?: boolean;
|
|
29
|
-
/**default false */
|
|
43
|
+
/** default false */
|
|
30
44
|
includeDigestInGet?: boolean;
|
|
31
45
|
/**default: Accept: jsonTypes.verbose, and (in post only) content-type: jsonTypes.verbose */
|
|
32
46
|
headers?: {
|