Skip to content
forked from Vectorized/dn404

Implementation of a co-joined ERC20 and ERC721 pair.

License

Notifications You must be signed in to change notification settings

grindytech/dn404

 
 

Repository files navigation

DN404 🥜

NPM CI

DN404 is an implementation of a co-joined ERC20 and ERC721 pair.

To learn more about these dual nature token pairs, you can read the full ERC-7631 spec.

  • Full compliance with the ERC20 and ERC721 specifications.
  • Transfers on one side will be reflected on the other side.
  • Pretty optimized.

Installation

To install with Foundry:

forge install vectorized/dn404

To install with Hardhat:

npm install dn404

Contracts

The Solidity smart contracts are located in the src directory.

src
├─ DN404"ERC20 contract for DN404"
├─ DN404Mirror"ERC721 contract for DN404"
├─ DN420"Single-contract ERC20 ERC1155 chimera"
└─ example
   ├─ SimpleDN404"Simple DN404 example as ERC20"
   └─ NFTMintDN404"Simple DN404 example as ERC721"

Contributing

Feel free to make a pull request.

Guidelines same as Solady's.

Safety

This is experimental software and is provided on an "as is" and "as available" basis.

We do not give any warranties and will not be liable for any loss incurred through any use of this codebase.

While DN404 has been heavily tested, there may be parts that exhibit unexpected emergent behavior when used with other code, or break in future Solidity versions.

Please always include your own thorough tests when using DN404 to make sure it works correctly with your code.

Upgradability

Most contracts in DN404 are compatible with both upgradeable and non-upgradeable (i.e. regular) contracts.

Please call any required internal initialization methods accordingly.

Acknowledgments

This repository is inspired by various sources:

About

Implementation of a co-joined ERC20 and ERC721 pair.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Solidity 100.0%