{"_id":"@carterjbastian/erc20-enumerable","name":"@carterjbastian/erc20-enumerable","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@carterjbastian/erc20-enumerable","version":"1.0.0","description":"An implementation of ERC20 with an enumerable _balances field","scripts":{"test":"npx hardhat test"},"repository":{"type":"git","url":"git+https://github.com/carterjbastian/erc20-enumerable.git"},"author":{"name":"Carter J. Bastian"},"license":"MIT","bugs":{"url":"https://github.com/carterjbastian/erc20-enumerable/issues"},"homepage":"https://github.com/carterjbastian/erc20-enumerable#readme","devDependencies":{"@nomiclabs/hardhat-ethers":"^2.0.6","@nomiclabs/hardhat-waffle":"^2.0.3","@openzeppelin/test-helpers":"^0.5.15","chai":"^4.3.6","ethereum-waffle":"^3.4.4","ethers":"^5.6.8","hardhat":"^2.9.7"},"dependencies":{"@openzeppelin/contracts":"^4.6.0"},"gitHead":"af09d3ac065139803262b69f88df7d38f0fc920c","_id":"@carterjbastian/erc20-enumerable@1.0.0","_nodeVersion":"16.13.1","_npmVersion":"8.1.2","dist":{"integrity":"sha512-wnKIiSpleXPCcKqVPDGxpoAK1HOW1mfHoW5IiEXqgFQSiJZU+/Iq4PvK0XIJ5nT0RIr3A4NNFe1x4XpCvCNInw==","shasum":"98757ddf891bdd872ea0a15af8b49a410467a4d3","tarball":"https://registry.npmjs.org/@carterjbastian/erc20-enumerable/-/erc20-enumerable-1.0.0.tgz","fileCount":21,"unpackedSize":132138,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCnh+5kqPenXBKlyhZOpO8ZJGc8n5H+Ek1QpMraNPprrAIhAMxpCfXE5U808e3YBsRrKyKmtaI/zEo3+DV2BawUmIhO"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJim8SHACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmoDMg/9E4gfbWrbOFZKHLn/giSA0xVZzR0sLvUIImc7BMY8pG7C90TA\r\ni8aGBftmqldIvXVcXPY+WqBW9X+vz71r4wGW5afR6xLDr7hwtYnEFs7/LUz/\r\nU6oGoBJd3RSZHhxvlqlAzFDBthuXIlEcOfQYDnD7KLzR9+umHTjQjot1lquU\r\nAAtVMRclgs/w8rKQcylv40lttiaZ9IVyzkgjL+L3ZoFfWiWiRgeAPqCO6kmN\r\n5TWis1vcegSNcUmRpOQm9/MCMo7XDV0L/afqF0VoAdf7QLiTKaEdw8WWw2CH\r\nn/1zCTrvCPh68PpRB4VzYfbKdkBbiVwUhXiCQVt5uckqteC7Sif+B7Cqrj7E\r\n0c42lgP3FDGFoFLpyIB5zxyj1OXYDcMABkz74z1snftmG3vDuCb7b+MiUMRO\r\n+H1NjGwSoizzuVRcT12u720D19KgS9IP52SvQvJmlTn+K9t9/3EHjWOD0Y9R\r\nE5uvyOUvOsSHhhJiRy4PklFE3lPJrKL14zrigdgaSNu7TEqBvexR/BZ4Lfr1\r\nqAxsPQWkfc82lW51ECaf3JL1AVCIc8vyogqTDmNv/Ne95ST7xBNuYgyMStHg\r\nBJgxpTX80bUZqCD5WdX0WvZUvbxRuAG0AYVSMehLhBf2UPw3QD7RTnE5lVqC\r\nqIe5tJYkCQyr1QyiCY3Xq0ITuwKJB6sb7QA=\r\n=c1gH\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"carterjbastian","email":"carter.bastian1@gmail.com"},"directories":{},"maintainers":[{"name":"carterjbastian","email":"carter.bastian1@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/erc20-enumerable_1.0.0_1654375559215_0.75180489498719"},"_hasShrinkwrap":false}},"time":{"created":"2022-06-04T20:45:59.130Z","1.0.0":"2022-06-04T20:45:59.394Z","modified":"2022-06-04T20:45:59.520Z"},"maintainers":[{"name":"carterjbastian","email":"carter.bastian1@gmail.com"}],"description":"An implementation of ERC20 with an enumerable _balances field","homepage":"https://github.com/carterjbastian/erc20-enumerable#readme","repository":{"type":"git","url":"git+https://github.com/carterjbastian/erc20-enumerable.git"},"author":{"name":"Carter J. Bastian"},"bugs":{"url":"https://github.com/carterjbastian/erc20-enumerable/issues"},"license":"MIT","readme":"# ERC20 Enumerable\n\nThis is a modifaction of the (current at the time) OpenZeppelin ERC20 implementation to use an\nEnumerableMap instead of a native mapping and provide getter logic to enumerate the \\_balances\nfor an ERC20 token.\n\n## Install and use\n\n```\nnpm install \"@carterjbastian/erc20-enumerable\"\n```\n\n## Testing\n\n```\nnpx hardhat test\n```\n\nI copied over the main tests from OpenZeppelin and converted them to Ethers. The test coverage seems fairly\ncomplete of traditional ERC20 functionality and approval niceties.\n\nI built this using hardhat and ethers. This led to testing issues (janky converting of Truffle tests\nwritten by OpenZeppelin to Waffle). I could have done this better by re-writing the test logic, but\nI really just wanted to get the tests passing as quickly as possible.\n\n## TODOs\n\n- Add test coverage of the new enumeration functionality.\n- Fix the janky type and variable scope conversion issues that came from converting the tests to waffle.\n- Figure out how to handle the fact that the mapping order is not guaranteed and if that has implications on calling multiple\n  times within a single function?\n- Add function to check if an address is in the balance map (which could be semantically different than)\n","readmeFilename":"README.md"}