1.26.0 • Published 2 years ago

nfiot-js v1.26.0

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

NFioT-JS

Interact with NFioT contracts in javascript

Using NFioTJS

See avalaible contracts

NFioTJs exports the Contract enum containing all available contracts:

enum Contract {
  NFTIOT
}

Get a contracts ABI

Use the getContractAbi function to get a contract's ABI:

import { getContractAbi, Contract } from "nfiot-js";

const nfiotAbi = getContractAbi(Contract.NFIOT);

Full example with ethers

NFioTJs exports types for each contract, which can be used alongside Web3 libraries like ethers:

import { ethers } from "ethers";
import { getContractAbi, Contract } from "nfiot-js";
import type { NFioT } from "nftio-js";

const provider = new ethers.providers.Web3Provider((window as any).ethereum);
const signer = provider.getSigner();

const nfiotAbi = getContractAbi(Contract.NFIOT);
const nfiotContract = new ethers.Contract(contractAddress, nfiotAbi, signer) as NFiot;
1.15.0

2 years ago

1.14.0

2 years ago

1.13.0

2 years ago

1.19.0

2 years ago

1.18.0

2 years ago

1.17.0

2 years ago

1.16.0

2 years ago

1.21.0

2 years ago

1.20.0

2 years ago

1.25.0

2 years ago

1.26.0

2 years ago

1.12.0

2 years ago

1.11.0

2 years ago

1.10.0

2 years ago

1.9.0

2 years ago

1.8.0

2 years ago

1.7.0

2 years ago

0.0.2

2 years ago

1.2.0

2 years ago

0.0.1

2 years ago

1.1.0

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago