Create an ERC20 Token

A very simple project to launch/access your own ERC20 Contract Address, login with metamask & connect with solidity methods available

In order to use ERC20 a Web3Connection instance object or Web3ConnectionOptions must be provided

import { ERC20 } from '@taikai/dappkit';

/* Create Instance */
const deployer = 
  new ERC20({ 
    web3Host: 'WEB3_LINK', 
    privateKey: '', });

await deployer.loadAbi(); // Only needed for deploy
const address = await deployer.connection.getAddress();

/* Deploy ERC20 Contract */
const tx = await deployer.deployJsonAbi(
    "YOUR_TOKEN_NAME",
    "YOUR_TOKEN_SYMBOL",
    "1000000000000000000000000",
    address
);

/* Use your new ERC20 Token */
const erc20 = new ERC20(web3connection, tx.contractAddress);
await erc20.start();

console.log(erc20.transferTokenAmount('0xADDRESS', 100));

Looking for more functions?

See all available functions here

Last updated