Add bisqJS and liquidJS npm modules.
This commit is contained in:
15
examples/nodejs/mempool-js/bitcoin/difficulty.ts
Normal file
15
examples/nodejs/mempool-js/bitcoin/difficulty.ts
Normal file
@@ -0,0 +1,15 @@
|
||||
import mempoolJS from "./../../../../src/index";
|
||||
|
||||
const init = async () => {
|
||||
try {
|
||||
const {
|
||||
bitcoin: { difficulty },
|
||||
} = mempoolJS();
|
||||
|
||||
const difficultyAdjustment = await difficulty.getDifficultyAdjustment();
|
||||
console.log(difficultyAdjustment);
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
}
|
||||
};
|
||||
init();
|
||||
Reference in New Issue
Block a user