Package Exports
- @portis/web3
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@portis/web3) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Quick Start
It should take no more than 5 minutes to get started with Portis 🚀
Register a DApp in the Portis Dashboard, and copy your DApp ID.
Install Portis and Web3
npm install @portis/web3 web3
Import and initialize a web3 instance
import Portis from '@portis/web3'; import Web3 from 'web3'; const portis = new Portis('YOUR_DAPP_ID', 'mainnet'); const web3 = new Web3(portis.provider);
Verify everything works by calling a web3 method such as getAccounts:
web3.eth.getAccounts((error, accounts) => { console.log(accounts); });
You are good to go! 👍
For more information see our docs 📕
License
MIT