mirror of
https://github.com/Brotocol-xyz/bro-sdk.git
synced 2026-01-12 06:44:18 +08:00
chore(docs): fix lint errors and remove unsed packages
This commit is contained in:
@@ -23,9 +23,9 @@ python -m http.server 8080
|
||||
|
||||
Open `http://localhost:8080` in your browser to view the documentation.
|
||||
|
||||
## README Code Snippets
|
||||
## README Examples
|
||||
|
||||
Version history of the README code snippets is tracked at [`../examples/code-snippets`](../examples/code-snippets).
|
||||
Version history of the README examples is tracked at [`../examples/code-snippets`](../examples/code-snippets).
|
||||
|
||||
### Dependencies
|
||||
|
||||
@@ -34,7 +34,5 @@ To read or write `examples/code-snippets`, you may need to temporarily install d
|
||||
```bash
|
||||
pnpm install -D ethers
|
||||
pnpm install -D bitcoinjs-lib
|
||||
pnpm install -D ecpair bip32
|
||||
pnpm install -D tiny-secp256k1
|
||||
pnpm install -D axios
|
||||
```
|
||||
|
||||
@@ -12,7 +12,7 @@ import {
|
||||
toSDKNumberOrUndefined,
|
||||
BridgeFromBitcoinInput,
|
||||
} from "../../../src/index"
|
||||
import { Psbt, payments, Signer, networks } from "bitcoinjs-lib"
|
||||
import { Psbt, payments, networks } from "bitcoinjs-lib"
|
||||
import axios from "axios"
|
||||
|
||||
const sdk = new BroSDK()
|
||||
@@ -99,6 +99,7 @@ const signPsbt: BridgeFromBitcoinInput["signPsbt"] = async tx => {
|
||||
for (const index of tx.signInputs) {
|
||||
// Get the input's sighash
|
||||
const input = psbt.data.inputs[index]
|
||||
// @ts-ignore
|
||||
const sighash = input.sighashType
|
||||
|
||||
// Sign the transaction using the mocked signTx function
|
||||
|
||||
Reference in New Issue
Block a user