Skip to content

Commit 74ee90e

Browse files
authored
Update ledger docs for new init options (#1457)
1 parent b94db75 commit 74ee90e

File tree

3 files changed

+8
-37
lines changed

3 files changed

+8
-37
lines changed

packages/demo/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
"@web3-onboard/injected-wallets": "^2.5.0",
3434
"@web3-onboard/keepkey": "^2.3.2",
3535
"@web3-onboard/keystone": "^2.3.2",
36-
"@web3-onboard/ledger": "^2.4.0",
36+
"@web3-onboard/ledger": "^2.4.1-alpha.1",
3737
"@web3-onboard/magic": "^2.1.3",
3838
"@web3-onboard/phantom": "^2.0.0-alpha.1",
3939
"@web3-onboard/portis": "^2.1.3",

packages/ledger/README.md

Lines changed: 6 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -4,45 +4,16 @@
44

55
### Install
66

7-
`npm i @web3-onboard/ledger`
7+
`npm i @web3-onboard/core @web3-onboard/ledger`
88

99
### Options
1010

1111
```typescript
12-
type LedgerOptions = {
13-
customNetwork?: CustomNetwork
14-
}
15-
16-
interface CustomNetwork {
17-
networkId: number
18-
genesis: GenesisBlock
19-
hardforks: Hardfork[]
20-
bootstrapNodes: BootstrapNode[]
21-
}
22-
23-
interface GenesisBlock {
24-
hash: string
25-
timestamp: string | null
26-
gasLimit: number
27-
difficulty: number
28-
nonce: string
29-
extraData: string
30-
stateRoot: string
31-
}
32-
33-
interface Hardfork {
34-
name: string
35-
block: number | null
36-
}
37-
38-
interface BootstrapNode {
39-
ip: string
40-
port: number | string
41-
network?: string
12+
interface LedgerOptions {
4213
chainId?: number
43-
id: string
44-
location: string
45-
comment: string
14+
bridge?: string
15+
infuraId?: string
16+
rpc?: { [chainId: number]: string }
4617
}
4718
```
4819

@@ -74,7 +45,7 @@ You may decide that on certain platforms you do not want to display this wallet
7445
import Onboard from '@web3-onboard/core'
7546
import ledgerModule from '@web3-onboard/ledger'
7647

77-
const ledger = ledgerModule({ filter: ['Safari'] })
48+
const ledger = ledgerModule()
7849

7950
const onboard = Onboard({
8051
// ... other Onboard options

packages/ledger/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@web3-onboard/ledger",
3-
"version": "2.4.0",
3+
"version": "2.4.1-alpha.1",
44
"description": "Ledger hardare wallet module for connecting to Web3-Onboard. Web3-Onboard makes it simple to connect Ethereum hardware and software wallets to your dapp. Features standardised spec compliant web3 providers for all supported wallets, framework agnostic modern javascript UI with code splitting, CSS customization, multi-chain and multi-account support, reactive wallet state subscriptions and real-time transaction state change notifications.",
55
"keywords": [
66
"Ethereum",

0 commit comments

Comments
 (0)