@webiny/api-headless-cms 5.39.2 → 5.39.3-beta.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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webiny/api-headless-cms",
|
|
3
|
-
"version": "5.39.
|
|
3
|
+
"version": "5.39.3-beta.0",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cms:base"
|
|
@@ -20,20 +20,20 @@
|
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@babel/runtime": "7.22.6",
|
|
22
22
|
"@graphql-tools/schema": "7.1.5",
|
|
23
|
-
"@webiny/api": "5.39.
|
|
24
|
-
"@webiny/api-i18n": "5.39.
|
|
25
|
-
"@webiny/api-security": "5.39.
|
|
26
|
-
"@webiny/api-tenancy": "5.39.
|
|
27
|
-
"@webiny/error": "5.39.
|
|
28
|
-
"@webiny/handler": "5.39.
|
|
29
|
-
"@webiny/handler-aws": "5.39.
|
|
30
|
-
"@webiny/handler-db": "5.39.
|
|
31
|
-
"@webiny/handler-graphql": "5.39.
|
|
32
|
-
"@webiny/lexical-converter": "5.39.
|
|
33
|
-
"@webiny/plugins": "5.39.
|
|
34
|
-
"@webiny/pubsub": "5.39.
|
|
35
|
-
"@webiny/utils": "5.39.
|
|
36
|
-
"@webiny/validation": "5.39.
|
|
23
|
+
"@webiny/api": "5.39.3-beta.0",
|
|
24
|
+
"@webiny/api-i18n": "5.39.3-beta.0",
|
|
25
|
+
"@webiny/api-security": "5.39.3-beta.0",
|
|
26
|
+
"@webiny/api-tenancy": "5.39.3-beta.0",
|
|
27
|
+
"@webiny/error": "5.39.3-beta.0",
|
|
28
|
+
"@webiny/handler": "5.39.3-beta.0",
|
|
29
|
+
"@webiny/handler-aws": "5.39.3-beta.0",
|
|
30
|
+
"@webiny/handler-db": "5.39.3-beta.0",
|
|
31
|
+
"@webiny/handler-graphql": "5.39.3-beta.0",
|
|
32
|
+
"@webiny/lexical-converter": "5.39.3-beta.0",
|
|
33
|
+
"@webiny/plugins": "5.39.3-beta.0",
|
|
34
|
+
"@webiny/pubsub": "5.39.3-beta.0",
|
|
35
|
+
"@webiny/utils": "5.39.3-beta.0",
|
|
36
|
+
"@webiny/validation": "5.39.3-beta.0",
|
|
37
37
|
"code-frame": "5.0.0",
|
|
38
38
|
"dot-prop": "6.0.1",
|
|
39
39
|
"graphql-tag": "2.12.6",
|
|
@@ -50,9 +50,9 @@
|
|
|
50
50
|
"@babel/cli": "7.22.6",
|
|
51
51
|
"@babel/core": "7.22.8",
|
|
52
52
|
"@babel/preset-env": "7.22.7",
|
|
53
|
-
"@webiny/api-wcp": "5.39.
|
|
54
|
-
"@webiny/cli": "5.39.
|
|
55
|
-
"@webiny/project-utils": "5.39.
|
|
53
|
+
"@webiny/api-wcp": "5.39.3-beta.0",
|
|
54
|
+
"@webiny/cli": "5.39.3-beta.0",
|
|
55
|
+
"@webiny/project-utils": "5.39.3-beta.0",
|
|
56
56
|
"apollo-graphql": "0.9.7",
|
|
57
57
|
"get-yarn-workspaces": "1.0.2",
|
|
58
58
|
"graphql": "15.8.0",
|
|
@@ -72,5 +72,5 @@
|
|
|
72
72
|
"build": "yarn webiny run build",
|
|
73
73
|
"watch": "yarn webiny run watch"
|
|
74
74
|
},
|
|
75
|
-
"gitHead": "
|
|
75
|
+
"gitHead": "bb0a2c8b43b2caa88f7a2d745a88039a520d124c"
|
|
76
76
|
}
|
|
@@ -1,29 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports.createCacheKey = void 0;
|
|
8
|
-
var
|
|
9
|
-
const getCacheKey = input => {
|
|
10
|
-
if (typeof input === "string") {
|
|
11
|
-
return input;
|
|
12
|
-
} else if (typeof input === "number") {
|
|
13
|
-
return `${input}`;
|
|
14
|
-
}
|
|
15
|
-
return JSON.stringify(input);
|
|
16
|
-
};
|
|
17
|
-
const createHash = input => {
|
|
18
|
-
const key = getCacheKey(input);
|
|
19
|
-
const hash = _crypto.default.createHash("sha1");
|
|
20
|
-
hash.update(key);
|
|
21
|
-
return hash.digest("hex");
|
|
22
|
-
};
|
|
7
|
+
var _utils = require("@webiny/utils");
|
|
23
8
|
class CacheKey {
|
|
24
9
|
constructor(keys) {
|
|
25
10
|
this.keys = keys;
|
|
26
|
-
this.key =
|
|
11
|
+
this.key = (0, _utils.createCacheKey)(keys, {
|
|
12
|
+
algorithm: "sha1",
|
|
13
|
+
encoding: "hex"
|
|
14
|
+
});
|
|
27
15
|
}
|
|
28
16
|
static create(key) {
|
|
29
17
|
return new CacheKey(key);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_utils","require","CacheKey","constructor","keys","key","createCacheKeyValue","algorithm","encoding","create","get","createCacheKey","exports"],"sources":["CacheKey.ts"],"sourcesContent":["import { ICacheKey } from \"./types\";\nimport { createCacheKey as createCacheKeyValue, ICacheKeyKeys } from \"@webiny/utils\";\n\nclass CacheKey implements ICacheKey {\n private readonly key: string;\n public readonly keys: ICacheKeyKeys;\n\n private constructor(keys: ICacheKeyKeys) {\n this.keys = keys;\n this.key = createCacheKeyValue(keys, {\n algorithm: \"sha1\",\n encoding: \"hex\"\n });\n }\n\n public static create(key: ICacheKeyKeys): ICacheKey {\n return new CacheKey(key);\n }\n\n public get(): string {\n return this.key;\n }\n}\n\nexport const createCacheKey = (key: ICacheKeyKeys) => {\n return CacheKey.create(key);\n};\n"],"mappings":";;;;;;AACA,IAAAA,MAAA,GAAAC,OAAA;AAEA,MAAMC,QAAQ,CAAsB;EAIxBC,WAAWA,CAACC,IAAmB,EAAE;IACrC,IAAI,CAACA,IAAI,GAAGA,IAAI;IAChB,IAAI,CAACC,GAAG,GAAG,IAAAC,qBAAmB,EAACF,IAAI,EAAE;MACjCG,SAAS,EAAE,MAAM;MACjBC,QAAQ,EAAE;IACd,CAAC,CAAC;EACN;EAEA,OAAcC,MAAMA,CAACJ,GAAkB,EAAa;IAChD,OAAO,IAAIH,QAAQ,CAACG,GAAG,CAAC;EAC5B;EAEOK,GAAGA,CAAA,EAAW;IACjB,OAAO,IAAI,CAACL,GAAG;EACnB;AACJ;AAEO,MAAMM,cAAc,GAAIN,GAAkB,IAAK;EAClD,OAAOH,QAAQ,CAACO,MAAM,CAACJ,GAAG,CAAC;AAC/B,CAAC;AAACO,OAAA,CAAAD,cAAA,GAAAA,cAAA"}
|
package/utils/caching/types.d.ts
CHANGED
package/utils/caching/types.js
CHANGED
|
@@ -3,5 +3,12 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
+
Object.defineProperty(exports, "ICacheKeyKeys", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function () {
|
|
9
|
+
return _utils.ICacheKeyKeys;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
var _utils = require("@webiny/utils");
|
|
6
13
|
|
|
7
14
|
//# sourceMappingURL=types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":[],"sources":["types.ts"],"sourcesContent":["
|
|
1
|
+
{"version":3,"names":["_utils","require"],"sources":["types.ts"],"sourcesContent":["import { ICacheKeyKeys } from \"@webiny/utils\";\n\nexport { ICacheKeyKeys };\n\nexport interface ICacheKey {\n get(): string;\n keys: ICacheKeyKeys;\n}\n\nexport interface ICache<T = any> {\n get(cacheKey: ICacheKey): T | null;\n set(cacheKey: ICacheKey, value: T): T;\n getOrSet(cacheKey: ICacheKey, cb: () => T): T;\n clear(cacheKey?: ICacheKey | ICacheKey[]): void;\n}\n"],"mappings":";;;;;;;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA"}
|