Skip to main content

TwentyTwoDecimalERC20

Git Source Inherits: ERC20 This is an example implementation to facilitate testing During deployment _tokenName and _tokenSymbol are set in constructor

Functions

constructor

Constructor sets params
constructor(string memory _name, string memory _symbol) ERC20(_name, _symbol);
Parameters
NameTypeDescription
_namestringName of the token
_symbolstringSymbol of the token

mint

Function that mints new tokens. Allows for free and open minting of tokens.
function mint(address to, uint256 amount) public;
Parameters
NameTypeDescription
toaddressrecipient address
amountuint256number of tokens to mint

decimals

Returns the number of decimals used to get its user representation.
function decimals() public view virtual override returns (uint8);