Comparing version 1.0.2 to 1.2.0
import GQLResultInterface, { GQLEdgeInterface, GQLNodeInterface } from "./faces"; | ||
export interface ArGql { | ||
export interface ArGqlInterface { | ||
run: (query: string, variables?: Record<string, unknown>) => Promise<GQLResultInterface>; | ||
@@ -11,2 +11,2 @@ all: (query: string, variables?: Record<string, unknown>) => Promise<GQLEdgeInterface[]>; | ||
} | ||
export default function arGql(endpointUrl?: string): ArGql; | ||
export declare function arGql(endpointUrl?: string): ArGqlInterface; |
@@ -50,2 +50,3 @@ "use strict"; | ||
exports.__esModule = true; | ||
exports.arGql = void 0; | ||
var tx_1 = require("./queries/tx"); | ||
@@ -152,2 +153,2 @@ function arGql(endpointUrl) { | ||
} | ||
exports["default"] = arGql; | ||
exports.arGql = arGql; |
{ | ||
"name": "ar-gql", | ||
"version": "1.0.2", | ||
"version": "1.2.0", | ||
"main": "dist/index", | ||
@@ -5,0 +5,0 @@ "types": "dist/index", |
@@ -16,6 +16,15 @@ # `ar-gql` version 1 | ||
> ## Migrating from version v0.x.x to v1.x.x | ||
> - Functions are no longer directly imported. You need to import an `ArGqlInterface` object and create instanced from it. See [Code Set Up](#code-set-up) section below | ||
> - As axios is no longer used internally `e.response` will always be undefined. You can catch regular `Error` objects with: | ||
> ```ts | ||
> e.message // status text | ||
> e.cause // http status number | ||
> ``` | ||
> in all other Fetch error cases there will be a standard Fetch `TypeError` with a relevent message. | ||
## Code Set Up | ||
```ts | ||
import arGql from 'ar-gql' | ||
import { arGql } from 'ar-gql' | ||
@@ -22,0 +31,0 @@ //... |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
97
14092
10
235