-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
350bfd1
commit bde790b
Showing
14 changed files
with
41 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
export { BlockchainnClientProvider } from './BlockchainClientProvider' | ||
export { BlockchainClientProvider } from './BlockchainClientProvider' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,2 @@ | ||
export * from './implementation' | ||
export * from './interfaces' | ||
export * from './types' |
7 changes: 7 additions & 0 deletions
7
sdk/blockchain-client-provider/src/interfaces/IBlockchainClient.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import type { PublicClient } from 'viem' | ||
|
||
/** | ||
* @name IBlockchainClient | ||
* @description The client for a particular chain | ||
*/ | ||
export type IBlockchainClient = PublicClient |
13 changes: 6 additions & 7 deletions
13
sdk/blockchain-client-provider/src/interfaces/IBlockchainClientProvider.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,16 @@ | ||
import { type BlockchainClient } from '../types/BlockchainClient' | ||
import { type IBlockchainClient } from './IBlockchainClient' | ||
import type { IChainInfo } from '@summerfi/sdk-common' | ||
|
||
/** | ||
* @name IBlockchainClientProvider | ||
* @description Interface for the configuration provider, which is used to retrieve configuration items which are | ||
* typically stored in environment variables, although it could also fetch them from other sources | ||
* @description Interface for the BlockchainClient provider, which is used to retrieve a BlockchainClient for a particular chain | ||
*/ | ||
export interface IBlockchainClientProvider { | ||
/** | ||
* @name getBlockchainClient | ||
* @description Retrieves a configuration item from the configuration provider | ||
* @param name The name of the configuration item to retrieve | ||
* @returns The value of the configuration item | ||
* @description Retrieves a BlockchainClient for a particular chain | ||
* @param chainInfo The chain information for the chain | ||
* @returns IBlockchainClient The client for a particular chain | ||
*/ | ||
getBlockchainClient(params: { chainInfo: IChainInfo }): BlockchainClient | ||
getBlockchainClient(params: { chainInfo: IChainInfo }): IBlockchainClient | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
export { type IBlockchainClientProvider } from './IBlockchainClientProvider' | ||
export * from './IBlockchainClientProvider' | ||
export * from './IBlockchainClient' |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
sdk/blockchain-client-provider/tests/blockchain-provider.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters