Created
February 25, 2025 13:34
-
-
Save arif-1498/48d496002a959bae16cf7d53146ee557 to your computer and use it in GitHub Desktop.
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.26+commit.8a97fa7a.js&optimize=false&runs=200&gist=
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // SPDX-License-Identifier: MIT | |
| // Compatible with OpenZeppelin Contracts ^5.0.0 | |
| pragma solidity ^0.8.22; | |
| import {ERC20} from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; | |
| import {ERC20Burnable} from "@openzeppelin/contracts/token/ERC20/extensions/ERC20Burnable.sol"; | |
| import {ERC20FlashMint} from "@openzeppelin/contracts/token/ERC20/extensions/ERC20FlashMint.sol"; | |
| import {ERC20Permit} from "@openzeppelin/contracts/token/ERC20/extensions/ERC20Permit.sol"; | |
| import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol"; | |
| contract MyToken is ERC20, ERC20Burnable, Ownable, ERC20Permit, ERC20FlashMint { | |
| constructor(address initialOwner) | |
| ERC20("Gold Token Coin", "GTC") | |
| Ownable(initialOwner) | |
| ERC20Permit("MyToken") | |
| {} | |
| function mint(address to, uint256 amount) public onlyOwner { | |
| _mint(to, amount); | |
| } | |
| } | |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Token code