Skip to content

Commit

Permalink
Refactor and rename graphql-client package to blockchain-providers (
Browse files Browse the repository at this point in the history
#70)

* rename `graphql-client` to `blockchain-providers`

* add `getUTxOSetFrom` function and improve TSDocs

* fix build

* refactor

* update pnpm-lock

* add mempool fetching

* add unconfirmed query

* add `streamUnspentBoxes` method

* add tests

* remove unused utxo set function

* compact gql test vectors

* Move IBlockchainProvider from common to blockchain-providers

* add query by address

* refactor

* fetch from mempool only

* add changeset and export from main package

* add `createCustomOperation` method

* refactor test

* refactor ErgoGraphQLProvider createCustomOperation
to createOperation
  • Loading branch information
arobsn authored Nov 13, 2023
1 parent 6c15dc3 commit feb2109
Show file tree
Hide file tree
Showing 42 changed files with 2,772 additions and 3,876 deletions.
7 changes: 7 additions & 0 deletions .changeset/gold-items-press.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@fleet-sdk/blockchain-providers": minor
---

Introduce `@fleet-sdk/blockchain-providers` package

- Add `ErgoGraphQLProvider` provider
3 changes: 2 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
node_modules
coverage
dist
dist
mockedGraphQLResponses.json
3 changes: 3 additions & 0 deletions packages/_test-vectors/index.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
import _boxes from "./mockedGraphQLBoxResponses.json";

export * from "./mockedBoxes";
export * from "./mockedTransactions";
export const mockedGraphQLBoxes = _boxes;
202 changes: 202 additions & 0 deletions packages/_test-vectors/mockedGraphQLBoxResponses.json

Large diffs are not rendered by default.

File renamed without changes.
15 changes: 15 additions & 0 deletions packages/blockchain-providers/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# @fleet-sdk/blockchain-providers [![License](https://badgen.net/github/license/fleet-sdk/fleet/)](https://github.com/fleet-sdk/fleet/blob/master/LICENSE) [![npm](https://badgen.net/npm/v/@fleet-sdk/blockchain-providers)](https://www.npmjs.com/package/@fleet-sdk/blockchain-providers)

Blockchain data client for ergo-graphql.

## Build

```sh
pnpm --filter blockchain-providers build
```

## Test

```sh
pnpm test:unit blockchain-providers
```
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@fleet-sdk/graphql-client",
"name": "@fleet-sdk/blockchain-providers",
"version": "0.0.0",
"description": "Blockchain data client for ergo-graphql",
"description": "Blockchain data providers",
"main": "./dist/index.cjs.js",
"module": "./dist/index.esm.js",
"types": "./dist/index.d.ts",
Expand Down
Loading

0 comments on commit feb2109

Please sign in to comment.