Skip to content

Instantly share code, notes, and snippets.

@0x62
0x62 / RpcApi.js
Created September 4, 2021 13:42
Hacky workaround
import { ethers } from 'ethers'
class RpcApi {
constructor({ endpoint, address, abi }) {
this._endpoint = endpoint
this._address = null
this._abi = null
this._id = 0
if (abi && address) this.setContract({ address, abi })