@geins/core 0.3.6 → 0.3.7
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/.turbo/turbo-build.log
CHANGED
|
@@ -2,5 +2,5 @@ yarn run v1.22.22
|
|
|
2
2
|
$ rollup -c
|
|
3
3
|
[36m
|
|
4
4
|
[1msrc/index.ts[22m → [1mdist/index.cjs, dist/index.esm.js[22m...[39m
|
|
5
|
-
[32mcreated [1mdist/index.cjs, dist/index.esm.js[22m in [1m6.
|
|
6
|
-
Done in
|
|
5
|
+
[32mcreated [1mdist/index.cjs, dist/index.esm.js[22m in [1m6.9s[22m[39m
|
|
6
|
+
Done in 7.43s.
|
package/CHANGELOG.md
CHANGED
|
@@ -11,7 +11,7 @@ export declare enum OperationType {
|
|
|
11
11
|
MUTATION = "mutation"
|
|
12
12
|
}
|
|
13
13
|
export interface RequestOptions {
|
|
14
|
-
fetchPolicy?:
|
|
14
|
+
fetchPolicy?: FetchPolicyOptions;
|
|
15
15
|
pollInterval?: number;
|
|
16
16
|
context?: any;
|
|
17
17
|
[key: string]: any;
|
|
@@ -27,6 +27,7 @@ export interface GraphQLQueryOptions {
|
|
|
27
27
|
queryAsString?: string | undefined;
|
|
28
28
|
variables?: any;
|
|
29
29
|
requestOptions?: RequestOptions;
|
|
30
|
+
log_to_console?: boolean;
|
|
30
31
|
}
|
|
31
32
|
export declare class MerchantApiClient {
|
|
32
33
|
private _cookieService;
|
package/dist/index.cjs
CHANGED
|
@@ -21432,7 +21432,7 @@ var GraphQLService = /** @class */ (function (_super) {
|
|
|
21432
21432
|
return [4 /*yield*/, this.verifyQueryOptions(options)];
|
|
21433
21433
|
case 1:
|
|
21434
21434
|
queryOptions = _b.sent();
|
|
21435
|
-
if (this.log_to_console && this._geinsSettings.environment !== 'prod') {
|
|
21435
|
+
if ((this.log_to_console || options.log_to_console) && this._geinsSettings.environment !== 'prod') {
|
|
21436
21436
|
console.log('[Geins] queryOptions:', queryOptions);
|
|
21437
21437
|
}
|
|
21438
21438
|
_a = this.cleanObject;
|
|
@@ -21462,7 +21462,7 @@ var GraphQLService = /** @class */ (function (_super) {
|
|
|
21462
21462
|
switch (_a.label) {
|
|
21463
21463
|
case 0:
|
|
21464
21464
|
_a.trys.push([0, 2, , 3]);
|
|
21465
|
-
if (this.log_to_console && this._geinsSettings.environment !== 'prod') {
|
|
21465
|
+
if ((this.log_to_console || options.log_to_console) && this._geinsSettings.environment !== 'prod') {
|
|
21466
21466
|
console.log('[Geins] mutation options:', options);
|
|
21467
21467
|
}
|
|
21468
21468
|
return [4 /*yield*/, this.runMutation(options)];
|
package/dist/index.esm.js
CHANGED
|
@@ -21430,7 +21430,7 @@ var GraphQLService = /** @class */ (function (_super) {
|
|
|
21430
21430
|
return [4 /*yield*/, this.verifyQueryOptions(options)];
|
|
21431
21431
|
case 1:
|
|
21432
21432
|
queryOptions = _b.sent();
|
|
21433
|
-
if (this.log_to_console && this._geinsSettings.environment !== 'prod') {
|
|
21433
|
+
if ((this.log_to_console || options.log_to_console) && this._geinsSettings.environment !== 'prod') {
|
|
21434
21434
|
console.log('[Geins] queryOptions:', queryOptions);
|
|
21435
21435
|
}
|
|
21436
21436
|
_a = this.cleanObject;
|
|
@@ -21460,7 +21460,7 @@ var GraphQLService = /** @class */ (function (_super) {
|
|
|
21460
21460
|
switch (_a.label) {
|
|
21461
21461
|
case 0:
|
|
21462
21462
|
_a.trys.push([0, 2, , 3]);
|
|
21463
|
-
if (this.log_to_console && this._geinsSettings.environment !== 'prod') {
|
|
21463
|
+
if ((this.log_to_console || options.log_to_console) && this._geinsSettings.environment !== 'prod') {
|
|
21464
21464
|
console.log('[Geins] mutation options:', options);
|
|
21465
21465
|
}
|
|
21466
21466
|
return [4 /*yield*/, this.runMutation(options)];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@geins/core",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.7",
|
|
4
4
|
"main": "dist/index.cjs",
|
|
5
5
|
"module": "dist/index.esm.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
23
23
|
"@geins/types": "*",
|
|
24
|
-
"@geins/eslint-config": "0.1.
|
|
24
|
+
"@geins/eslint-config": "0.1.7",
|
|
25
25
|
"@rollup/plugin-commonjs": "^28.0.0",
|
|
26
26
|
"@rollup/plugin-graphql": "^2.0.5",
|
|
27
27
|
"@rollup/plugin-node-resolve": "^15.3.0",
|
|
@@ -26,7 +26,7 @@ export enum OperationType {
|
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
export interface RequestOptions {
|
|
29
|
-
fetchPolicy?:
|
|
29
|
+
fetchPolicy?: FetchPolicyOptions;
|
|
30
30
|
pollInterval?: number;
|
|
31
31
|
context?: any;
|
|
32
32
|
[key: string]: any;
|
|
@@ -44,6 +44,7 @@ export interface GraphQLQueryOptions {
|
|
|
44
44
|
queryAsString?: string | undefined;
|
|
45
45
|
variables?: any;
|
|
46
46
|
requestOptions?: RequestOptions;
|
|
47
|
+
log_to_console?: boolean;
|
|
47
48
|
}
|
|
48
49
|
|
|
49
50
|
export class MerchantApiClient {
|
|
@@ -64,7 +64,7 @@ export class GraphQLService extends BaseApiService {
|
|
|
64
64
|
try {
|
|
65
65
|
const queryOptions = await this.verifyQueryOptions(options);
|
|
66
66
|
|
|
67
|
-
if (this.log_to_console && this._geinsSettings.environment !== 'prod') {
|
|
67
|
+
if ((this.log_to_console || options.log_to_console) && this._geinsSettings.environment !== 'prod') {
|
|
68
68
|
console.log('[Geins] queryOptions:', queryOptions);
|
|
69
69
|
}
|
|
70
70
|
const result = this.cleanObject(await this.runQuery(queryOptions));
|
|
@@ -83,7 +83,7 @@ export class GraphQLService extends BaseApiService {
|
|
|
83
83
|
*/
|
|
84
84
|
async mutation<T = any>(options: GraphQLQueryOptions): Promise<T | null> {
|
|
85
85
|
try {
|
|
86
|
-
if (this.log_to_console && this._geinsSettings.environment !== 'prod') {
|
|
86
|
+
if ((this.log_to_console || options.log_to_console) && this._geinsSettings.environment !== 'prod') {
|
|
87
87
|
console.log('[Geins] mutation options:', options);
|
|
88
88
|
}
|
|
89
89
|
|