Skip to content
This repository was archived by the owner on Jan 8, 2026. It is now read-only.

Commit 225eb6a

Browse files
authored
Feat/export helpercontracts (#55)
* feat: added exports to index * fix: added index to coverage ignore * feat: added interface
1 parent e9753f1 commit 225eb6a

File tree

3 files changed

+14
-1
lines changed

3 files changed

+14
-1
lines changed

jest.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ module.exports = {
2222
coveragePathIgnorePatterns: [
2323
'packages/contract-helpers/src/ui-incentive-data-provider/typechain',
2424
'packages/contract-helpers/src/wallet-balance-provider/typechain',
25+
'packages/contract-helpers/src/index.ts',
2526
],
2627
modulePathIgnorePatterns: ['node_modules'],
2728
preset: 'ts-jest',
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
export * from './ui-incentive-data-provider';
2+
export * from './wallet-balance-provider';

packages/contract-helpers/src/ui-incentive-data-provider/index.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,23 @@ import {
99
} from './types/UiIncentiveDataProviderTypes';
1010
export * from './types/UiIncentiveDataProviderTypes';
1111

12+
export interface UiIncentiveDataProviderInterface {
13+
getAllIncentives: (
14+
user: string,
15+
) => Promise<FullReservesIncentiveDataResponse>;
16+
getReservesIncentives: () => Promise<ReserveIncentiveDataResponse[]>;
17+
getUserReservesIncentives: (
18+
user: string,
19+
) => Promise<UserReserveIncentiveDataResponse[]>;
20+
}
1221
export interface UiIncentiveDataProviderContext {
1322
incentiveDataProviderAddress: string;
1423
lendingPoolAddressProvider: string;
1524
provider: providers.Provider;
1625
}
1726

18-
export class UiIncentiveDataProvider {
27+
export class UiIncentiveDataProvider
28+
implements UiIncentiveDataProviderInterface {
1929
private readonly _contract: UiIncentiveDataProviderContract;
2030

2131
private readonly _lendingPoolAddressProvider: string;

0 commit comments

Comments
 (0)