@rango-dev/wallets-core v0.39.0
Add a type for child classes (Metamask, ..) to ensure they are implementing required methods.
Template
Template for creating a new provider
const WALLET = WalletType.COINBASE;
class TemplateWallet extends Wallet<InstanceType> implements WalletInterface {
constructor(onChangeState: EventHandler) {
super(WALLET, onChangeState);
// let instance = metamask_instance();
// if (!!instance) {
// this.setProvider(instance);
// this.subscirbe();
// }
}
async check() {}
async connect() {}
async disconnect() {}
async subscribe() {}
}
export default {
initializer: TemplateWallet,
type: WALLET
};
TODO
- subscirbe -> subscribe
- add eagerConnect to core (maybe instead of check?)
- Reading from wallets (like
eth_chainId
,eth_accounts
) should've a timeout. because sometimes wallet doesn't responding corretly. But requesting (likeeth_requestAccounts
) shouldn't have a timeout, because it opens a popup and it take some time to get a confirmation or rejction from user.
- add provider to
checkWalletProviders
2 months ago
1 month ago
2 months ago
2 months ago
2 months ago
5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
5 months ago
4 months ago
5 months ago
6 months ago
3 months ago
3 months ago
3 months ago
4 months ago
4 months ago
4 months ago
4 months ago
6 months ago
6 months ago
6 months ago
6 months ago
6 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
8 months ago
8 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
9 months ago
10 months ago
10 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
12 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
12 months ago
1 year ago
12 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
1 year ago
2 years ago
1 year ago
2 years ago
1 year ago
1 year ago
1 year ago
2 years ago
1 year ago
2 years ago
1 year ago
2 years ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago