Security News
Weekly Downloads Now Available in npm Package Search Results
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
@xtoken/abis
Advanced tools
Package containing all the xToken contract ABIs and addresses.
yarn add @xtoken/abis
yarn build
Link @xtoken/abis
package via yarn for local development and testing the integration on the UI
$ cd abis
$ yarn link # @xtoken/abis package will be linked to the local copy
$ cd cafe
$ yarn link @xtoken/abis # This will create a symlink named cafe/node_modules/@xtoken/abis that links to the local copy of the xToken abis project
$ yarn unlink # To unlink the installed package
To automatically fix eslint
and prettier
formatting issues, run:
yarn fix
import { ethers } from 'ethers'
import { Abis, ADDRESSES, X_AAVE_A } from '@xtoken/abis'
// Setup provider
const provider = new ethers.providers.InfuraProvider('homestead', '<API KEY>')
const network = await provider.getNetwork()
const { chainId } = network
// Initialise xAAVEa contract
const xaaveContract = new ethers.Contract(ADDRESSES[X_AAVE_A][chainId], Abis.xAAVE, provider)
1. Add Contract constants in constants.ts
2. Add mainnet addresses based on the constants in addresses.ts
3. Add the contract abis in abis/
4. Export the ABIs in abis/index.ts
FAQs
xToken Contract ABIs
We found that @xtoken/abis demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 6 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.
Security News
A Stanford study reveals 9.5% of engineers contribute almost nothing, costing tech $90B annually, with remote work fueling the rise of "ghost engineers."
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.