Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@bn-onboard/common

Package Overview
Dependencies
Maintainers
3
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@bn-onboard/common - npm Package Compare versions

Comparing version 2.0.0-alpha.1 to 2.0.0-alpha.2

dist/entry-modal.d.ts

1

dist/index.d.ts

@@ -6,3 +6,4 @@ import { RequestPatch, EventCallback, AccountSelectAPI, SelectAccountOptions, BasePath, DerivationPath, Asset, ScanAccounts, ScanAccountsOptions, AccountAddress, Account, AccountsList, AppMetadata, RecommendedInjectedWallets, WalletInit, WalletHelpers, WalletExclusions, InjectedWalletOptions, APIKey, Device, WalletModule, GetInterfaceHelpers, InjectedWalletModule, Platform, DeviceOS, DeviceBrowser, DeviceOSName, DeviceBrowserName, DeviceType, ChainId, RpcUrl, WalletInterface, ProviderMessage, ProviderInfo, ProviderAccounts, ProviderEvent, SimpleEventEmitter, ConnectListener, DisconnectListener, MessageListener, ChainListener, AccountsListener, Balance, EthAccountsRequest, EthChainIdRequest, EthBalanceRequest, EIP1102Request, EIP3085Request, EIP3326Request, AddChainParams, EIP1193Provider, MeetOneProvider, BinanceProvider, InjectedNameSpace, CustomWindow, InjectedProvider, ProviderRpcErrorCode, Chain, TokenSymbol, CustomNetwork } from './types';

export { default as accountSelect } from './account-select';
export { entryModal } from './entry-modal';
export { ProviderIdentityFlag, ProviderLabel, InjectedNameSpace };
export type { RequestPatch, EventCallback, AccountSelectAPI, SelectAccountOptions, BasePath, DerivationPath, Asset, ScanAccounts, ScanAccountsOptions, AccountAddress, Account, AccountsList, AppMetadata, RecommendedInjectedWallets, WalletInit, WalletHelpers, WalletExclusions, InjectedWalletOptions, APIKey, Device, WalletModule, GetInterfaceHelpers, InjectedWalletModule, Platform, DeviceOS, DeviceBrowser, DeviceOSName, DeviceBrowserName, DeviceType, ChainId, RpcUrl, WalletInterface, ProviderMessage, ProviderInfo, ProviderAccounts, ProviderEvent, SimpleEventEmitter, ConnectListener, DisconnectListener, MessageListener, ChainListener, AccountsListener, Balance, EthAccountsRequest, EthChainIdRequest, EthBalanceRequest, EIP1102Request, EIP3085Request, EIP3326Request, AddChainParams, EIP1193Provider, MeetOneProvider, BinanceProvider, CustomWindow, InjectedProvider, ProviderRpcErrorCode, Chain, TokenSymbol, CustomNetwork };

4

dist/types.d.ts

@@ -205,4 +205,6 @@ import type { ExternalProvider } from '@ethersproject/providers';

gasPrice?: string;
to?: string;
to: string;
value?: string;
maxFeePerGas?: string;
maxPriorityFeePerGas?: string;
nonce?: string;

@@ -209,0 +211,0 @@ }

{
"name": "@bn-onboard/common",
"version": "2.0.0-alpha.1",
"version": "2.0.0-alpha.2",
"scripts": {

@@ -39,8 +39,3 @@ "build": "rollup -c",

},
"dependencies": {
"@ethersproject/providers": "^5.5.0",
"eip-712": "^0.4.3",
"joi": "^17.4.2",
"rxjs": "^7.3.0"
}
"dependencies": {}
}

@@ -1,70 +0,3 @@

# Onboard V2 Core Package
# @bn-onboard/common
## Getting Started
```javascript
import Onboard from '@bn-onboard/core'
import InjectedWallets from '@bn-onboard/injected-wallets'
const injectedWallet = InjectedWallets()
const onboard = Onboard({
// wallet modules that you would like the user to be able to select from
wallets: [injectedWallet],
// additional metadata for app information
appMetadata: {
name: '<APP_NAME>',
icon: '<APP_SVG_ICON_STRING>',
description: '<APP_DESCRIPTION'
},
// a mapping of locales to i18n options (https://github.com/blocknative/onboard/blob/feature/v2/packages/core/src/types.ts#L134)
// can be used to replace default text or add multiple language support
i18n: {
es: {
connect: {
selectingWallet: {
sidebar: {
heading: 'Comenzar'
}
}
}
}
}
})
// subscribe to all state updates and log
const state$ = onboard.state.select()
state$.subscribe(console.log)
// or you can subscribe to a slice of state for when it updates
const wallets$ = onboard.state.select('wallets')
wallets$.subscribe(console.log)
// Add networks that are valid for your app
onboard.addChains([
{
id: '0x1',
token: 'ETH',
label: 'Ethereum Mainnet',
rpcUrl: 'https://mainnet.infura.io/v3/ababf9851fd845d0a167825f97eeb12b'
},
{
id: '0x4',
token: 'rETH',
label: 'Ethereum Rinkeby Testnet',
rpcUrl: 'https://rinkeby.infura.io/v3/ababf9851fd845d0a167825f97eeb12b'
},
{
id: '0x89',
token: 'MATIC',
label: 'Matic Mainnet',
rpcUrl: 'https://matic-mainnet.chainstacklabs.com'
}
])
// connect a user wallet
onboard.connectWallet()
// set chain to mainnet
onboard.setChain('0x1')
```
## A collection of functions and types that are shared across various packages in the Onboard V2 monorepo

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc