@stonecrop/graphql-client 0.4.37 → 0.6.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/dist/index.js
CHANGED
|
@@ -44,6 +44,7 @@ const metaParser = (obj) => {
|
|
|
44
44
|
const methods = {
|
|
45
45
|
getMeta: async (doctype, url) => {
|
|
46
46
|
const client = new GraphQLClient(url || '/graphql', {
|
|
47
|
+
fetch: window.fetch,
|
|
47
48
|
jsonSerializer: {
|
|
48
49
|
stringify: obj => JSON.stringify(obj), // process the request object before sending; leave as default JSON
|
|
49
50
|
parse: metaParser, // process the response meta object
|
package/dist/src/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AACnC,OAAO,QAAQ,MAAM,cAAc,CAAA;AACnC,OAAO,KAAK,EAAoB,YAAY,EAAE,MAAM,SAAS,CAAA;AAkC7D;;;;;;GAMG;AACH,QAAA,MAAM,OAAO;uBACa,MAAM,QAAQ,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AACnC,OAAO,QAAQ,MAAM,cAAc,CAAA;AACnC,OAAO,KAAK,EAAoB,YAAY,EAAE,MAAM,SAAS,CAAA;AAkC7D;;;;;;GAMG;AACH,QAAA,MAAM,OAAO;uBACa,MAAM,QAAQ,MAAM,KAAG,OAAO,CAAC,YAAY,CAAC;CAgBrE,CAAA;AAED,YAAY,EAAE,IAAI,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,SAAS,CAAA;AAC7D,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stonecrop/graphql-client",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"author": {
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"decimal.js": "^10.4.3",
|
|
38
38
|
"graphql": "~16.6.0",
|
|
39
39
|
"graphql-request": "~6.0.0",
|
|
40
|
-
"@stonecrop/stonecrop": "0.
|
|
40
|
+
"@stonecrop/stonecrop": "0.6.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@eslint/js": "^9.38.0",
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
"prepublish": "heft build && vite build && rushx docs",
|
|
69
69
|
"build": "heft build && vite build && rushx docs",
|
|
70
70
|
"dev": "vite",
|
|
71
|
-
"docs": "
|
|
71
|
+
"docs": "bash ../common/scripts/run-docs.sh graphql_client",
|
|
72
72
|
"lint": "eslint .",
|
|
73
73
|
"preview": "vite preview"
|
|
74
74
|
}
|
package/src/index.ts
CHANGED
|
@@ -47,6 +47,7 @@ const metaParser = (obj: string): MetaParser => {
|
|
|
47
47
|
const methods = {
|
|
48
48
|
getMeta: async (doctype: string, url?: string): Promise<MetaResponse> => {
|
|
49
49
|
const client = new GraphQLClient(url || '/graphql', {
|
|
50
|
+
fetch: window.fetch,
|
|
50
51
|
jsonSerializer: {
|
|
51
52
|
stringify: obj => JSON.stringify(obj), // process the request object before sending; leave as default JSON
|
|
52
53
|
parse: metaParser, // process the response meta object
|