triwallet
TypeScript icon, indicating that this package has built-in type declarations

0.0.9 • Public • Published

triwallet Integration Guide

Add wallet3 to your project dependencies

With Yarn

yarn add triwallet

or with NPM

npm install triwallet

getWalletAddress for a particular wallet

With JavaScript

const { TriWallet, WALLET, NETWORK } = require('triwallet');
const triWallet = new TriWallet(WALLET.METAMASK);
const walletAddress = await triWallet.getWalletAddress(NETWORK.POLYGON);

or with TypeScript

import { TriWallet, WALLET, NETWORK } from 'triwallet';
const triWallet = new TriWallet(WALLET.METAMASK);
const walletAddress = await triWallet.getWalletAddress(NETWORK.POLYGON);

getWalletAddress for a testnet wallet

With JavaScript

const { TriWallet, WALLET, NETWORK } = require('triwallet');
const triWallet = new TriWallet(WALLET.METAMASK);
triWallet.enableTestnet();
const walletAddress = await triWallet.getWalletAddress(NETWORK.POLYGON);

or with TypeScript

import { TriWallet, WALLET, NETWORK } from 'triwallet';
const triWallet = new TriWallet(WALLET.METAMASK);
triWallet.enableTestnet();
const walletAddress = await triWallet.getWalletAddress(NETWORK.POLYGON);

Readme

Keywords

none

Package Sidebar

Install

npm i triwallet

Weekly Downloads

14

Version

0.0.9

License

ISC

Unpacked Size

30 kB

Total Files

69

Last publish

Collaborators

  • azharsabri
  • sayedazharsabri