@1delta/data-sdk 0.0.5 → 0.0.7
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/dist/index.js +17 -0
- package/dist/index.mjs +17 -1
- package/dist/lending.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
// src/chains.ts
|
|
4
4
|
var GLOBAL_CHAIN_DATA_KEY = "__1delta_chain_registry__";
|
|
5
|
+
globalThis[GLOBAL_CHAIN_DATA_KEY] = {};
|
|
5
6
|
function getGlobalData() {
|
|
6
7
|
return globalThis[GLOBAL_CHAIN_DATA_KEY];
|
|
7
8
|
}
|
|
@@ -12,6 +13,20 @@ var chains = () => getGlobalData();
|
|
|
12
13
|
|
|
13
14
|
// src/lending.ts
|
|
14
15
|
var GLOBAL_LENDER_DATA_KEY = "__1delta_lender_registry__";
|
|
16
|
+
globalThis[GLOBAL_LENDER_DATA_KEY] = {
|
|
17
|
+
aaveTokens: {},
|
|
18
|
+
aavePools: {},
|
|
19
|
+
compoundV3Pools: {},
|
|
20
|
+
morphoPools: {},
|
|
21
|
+
compoundV3BaseData: {},
|
|
22
|
+
compoundV2Pools: {},
|
|
23
|
+
compoundV2Tokens: {},
|
|
24
|
+
initConfig: {},
|
|
25
|
+
aaveReserves: {},
|
|
26
|
+
compoundV2Reserves: {},
|
|
27
|
+
compoundV3Reserves: {},
|
|
28
|
+
aaveOracles: {}
|
|
29
|
+
};
|
|
15
30
|
function getGlobalData2() {
|
|
16
31
|
return globalThis[GLOBAL_LENDER_DATA_KEY];
|
|
17
32
|
}
|
|
@@ -45,6 +60,7 @@ function initializeLenderData({
|
|
|
45
60
|
}
|
|
46
61
|
var aaveTokens = () => getGlobalData2()?.aaveTokens;
|
|
47
62
|
var aavePools = () => getGlobalData2()?.aavePools;
|
|
63
|
+
var aaveOracles = () => getGlobalData2()?.aaveOracles;
|
|
48
64
|
var aaveReserves = () => getGlobalData2()?.aaveReserves;
|
|
49
65
|
var compoundV3Reserves = () => getGlobalData2()?.compoundV3Reserves;
|
|
50
66
|
var compoundV2Reserves = () => getGlobalData2()?.compoundV2Reserves;
|
|
@@ -55,6 +71,7 @@ var compoundV2Pools = () => getGlobalData2()?.compoundV2Pools;
|
|
|
55
71
|
var compoundV2Tokens = () => getGlobalData2()?.compoundV2Tokens;
|
|
56
72
|
var initConfig = () => getGlobalData2()?.initConfig;
|
|
57
73
|
|
|
74
|
+
exports.aaveOracles = aaveOracles;
|
|
58
75
|
exports.aavePools = aavePools;
|
|
59
76
|
exports.aaveReserves = aaveReserves;
|
|
60
77
|
exports.aaveTokens = aaveTokens;
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
// src/chains.ts
|
|
2
2
|
var GLOBAL_CHAIN_DATA_KEY = "__1delta_chain_registry__";
|
|
3
|
+
globalThis[GLOBAL_CHAIN_DATA_KEY] = {};
|
|
3
4
|
function getGlobalData() {
|
|
4
5
|
return globalThis[GLOBAL_CHAIN_DATA_KEY];
|
|
5
6
|
}
|
|
@@ -10,6 +11,20 @@ var chains = () => getGlobalData();
|
|
|
10
11
|
|
|
11
12
|
// src/lending.ts
|
|
12
13
|
var GLOBAL_LENDER_DATA_KEY = "__1delta_lender_registry__";
|
|
14
|
+
globalThis[GLOBAL_LENDER_DATA_KEY] = {
|
|
15
|
+
aaveTokens: {},
|
|
16
|
+
aavePools: {},
|
|
17
|
+
compoundV3Pools: {},
|
|
18
|
+
morphoPools: {},
|
|
19
|
+
compoundV3BaseData: {},
|
|
20
|
+
compoundV2Pools: {},
|
|
21
|
+
compoundV2Tokens: {},
|
|
22
|
+
initConfig: {},
|
|
23
|
+
aaveReserves: {},
|
|
24
|
+
compoundV2Reserves: {},
|
|
25
|
+
compoundV3Reserves: {},
|
|
26
|
+
aaveOracles: {}
|
|
27
|
+
};
|
|
13
28
|
function getGlobalData2() {
|
|
14
29
|
return globalThis[GLOBAL_LENDER_DATA_KEY];
|
|
15
30
|
}
|
|
@@ -43,6 +58,7 @@ function initializeLenderData({
|
|
|
43
58
|
}
|
|
44
59
|
var aaveTokens = () => getGlobalData2()?.aaveTokens;
|
|
45
60
|
var aavePools = () => getGlobalData2()?.aavePools;
|
|
61
|
+
var aaveOracles = () => getGlobalData2()?.aaveOracles;
|
|
46
62
|
var aaveReserves = () => getGlobalData2()?.aaveReserves;
|
|
47
63
|
var compoundV3Reserves = () => getGlobalData2()?.compoundV3Reserves;
|
|
48
64
|
var compoundV2Reserves = () => getGlobalData2()?.compoundV2Reserves;
|
|
@@ -53,4 +69,4 @@ var compoundV2Pools = () => getGlobalData2()?.compoundV2Pools;
|
|
|
53
69
|
var compoundV2Tokens = () => getGlobalData2()?.compoundV2Tokens;
|
|
54
70
|
var initConfig = () => getGlobalData2()?.initConfig;
|
|
55
71
|
|
|
56
|
-
export { aavePools, aaveReserves, aaveTokens, chains, compoundV2Pools, compoundV2Reserves, compoundV2Tokens, compoundV3BaseData, compoundV3Pools, compoundV3Reserves, initConfig, initializeChainData, initializeLenderData, morphoPools };
|
|
72
|
+
export { aaveOracles, aavePools, aaveReserves, aaveTokens, chains, compoundV2Pools, compoundV2Reserves, compoundV2Tokens, compoundV3BaseData, compoundV3Pools, compoundV3Reserves, initConfig, initializeChainData, initializeLenderData, morphoPools };
|
package/dist/lending.d.ts
CHANGED
|
@@ -99,6 +99,7 @@ export declare function initializeLenderData({ aaveTokensOverride, aavePoolsOver
|
|
|
99
99
|
}): void;
|
|
100
100
|
export declare const aaveTokens: () => AaveTokensType;
|
|
101
101
|
export declare const aavePools: () => AavePoolsType;
|
|
102
|
+
export declare const aaveOracles: () => OracleMap;
|
|
102
103
|
export declare const aaveReserves: () => GeneralReservesMap;
|
|
103
104
|
export declare const compoundV3Reserves: () => GeneralReservesMap;
|
|
104
105
|
export declare const compoundV2Reserves: () => GeneralReservesMap;
|