@web3-onboard/particle-network
Wallet module for connecting Particle Network to web3-onboard
Install
npm i @web3-onboard/core @web3-onboard/particle-network
Options
See the Particle Network Docs for the extensive list of options.
Usage
import Onboard from '@web3-onboard/core'
import particleModule from '@web3-onboard/particle-network'
const particle = particleModule({
projectId: 'YOUR PROJECT ID',
clientKey: 'YOUR CLIENT KEY',
appId: 'YOUR APP ID'
})
const onboard = Onboard({
wallets: [
particle
]
})
const connectedWallets = await onboard.connectWallet()
console.log(connectedWallets)
Types
type AuthTypes = 'email' | 'phone' | 'google' | 'apple' | 'twitter' | 'facebook' | 'microsoft' | 'linkedin' | 'github' | 'twitch' | 'discord';
interface PreferredAuthType {
type: AuthTypes;
setAsDisplay: boolean;
}
interface ParticleAuthModuleOptions {
projectId: string;
clientKey: string;
appId: string;
chainName?: string;
chainId?: number;
wallet?: object;
preferredAuthType?: AuthTypes | PreferredAuthType;
}