@graphql-codegen/plugin-helpers 2.7.2-alpha-20221025134913-ec8a36be2 → 2.7.2-alpha-20221031143038-b4e11f6bc
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/cjs/errors.js +18 -0
- package/cjs/index.js +1 -0
- package/esm/errors.js +13 -0
- package/esm/index.js +1 -0
- package/package.json +1 -1
- package/typings/errors.d.cts +7 -0
- package/typings/errors.d.ts +7 -0
- package/typings/index.d.cts +1 -0
- package/typings/index.d.ts +1 -0
- package/typings/types.d.cts +1 -0
- package/typings/types.d.ts +1 -0
package/cjs/errors.js
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isDetailedError = exports.DetailedError = void 0;
|
|
4
|
+
class DetailedError extends Error {
|
|
5
|
+
constructor(message, details, source) {
|
|
6
|
+
super(message);
|
|
7
|
+
this.message = message;
|
|
8
|
+
this.details = details;
|
|
9
|
+
this.source = source;
|
|
10
|
+
Object.setPrototypeOf(this, DetailedError.prototype);
|
|
11
|
+
Error.captureStackTrace(this, DetailedError);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
exports.DetailedError = DetailedError;
|
|
15
|
+
function isDetailedError(error) {
|
|
16
|
+
return error.details;
|
|
17
|
+
}
|
|
18
|
+
exports.isDetailedError = isDetailedError;
|
package/cjs/index.js
CHANGED
|
@@ -8,6 +8,7 @@ tslib_1.__exportStar(require("./types.js"), exports);
|
|
|
8
8
|
tslib_1.__exportStar(require("./utils.js"), exports);
|
|
9
9
|
tslib_1.__exportStar(require("./helpers.js"), exports);
|
|
10
10
|
tslib_1.__exportStar(require("./federation.js"), exports);
|
|
11
|
+
tslib_1.__exportStar(require("./errors.js"), exports);
|
|
11
12
|
tslib_1.__exportStar(require("./getCachedDocumentNodeFromSchema.js"), exports);
|
|
12
13
|
tslib_1.__exportStar(require("./oldVisit.js"), exports);
|
|
13
14
|
tslib_1.__exportStar(require("./profiler.js"), exports);
|
package/esm/errors.js
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export class DetailedError extends Error {
|
|
2
|
+
constructor(message, details, source) {
|
|
3
|
+
super(message);
|
|
4
|
+
this.message = message;
|
|
5
|
+
this.details = details;
|
|
6
|
+
this.source = source;
|
|
7
|
+
Object.setPrototypeOf(this, DetailedError.prototype);
|
|
8
|
+
Error.captureStackTrace(this, DetailedError);
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
export function isDetailedError(error) {
|
|
12
|
+
return error.details;
|
|
13
|
+
}
|
package/esm/index.js
CHANGED
|
@@ -3,6 +3,7 @@ export * from './types.js';
|
|
|
3
3
|
export * from './utils.js';
|
|
4
4
|
export * from './helpers.js';
|
|
5
5
|
export * from './federation.js';
|
|
6
|
+
export * from './errors.js';
|
|
6
7
|
export * from './getCachedDocumentNodeFromSchema.js';
|
|
7
8
|
export * from './oldVisit.js';
|
|
8
9
|
export * from './profiler.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@graphql-codegen/plugin-helpers",
|
|
3
|
-
"version": "2.7.2-alpha-
|
|
3
|
+
"version": "2.7.2-alpha-20221031143038-b4e11f6bc",
|
|
4
4
|
"description": "GraphQL Code Generator common utils and types",
|
|
5
5
|
"peerDependencies": {
|
|
6
6
|
"graphql": "^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0 || ^16.0.0"
|
package/typings/index.d.cts
CHANGED
|
@@ -3,6 +3,7 @@ export * from './types.cjs';
|
|
|
3
3
|
export * from './utils.cjs';
|
|
4
4
|
export * from './helpers.cjs';
|
|
5
5
|
export * from './federation.cjs';
|
|
6
|
+
export * from './errors.cjs';
|
|
6
7
|
export * from './getCachedDocumentNodeFromSchema.cjs';
|
|
7
8
|
export * from './oldVisit.cjs';
|
|
8
9
|
export * from './profiler.cjs';
|
package/typings/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ export * from './types.js';
|
|
|
3
3
|
export * from './utils.js';
|
|
4
4
|
export * from './helpers.js';
|
|
5
5
|
export * from './federation.js';
|
|
6
|
+
export * from './errors.js';
|
|
6
7
|
export * from './getCachedDocumentNodeFromSchema.js';
|
|
7
8
|
export * from './oldVisit.js';
|
|
8
9
|
export * from './profiler.js';
|
package/typings/types.d.cts
CHANGED
package/typings/types.d.ts
CHANGED