{"bugs":{"url":"https://github.com/EthWorks/Waffle/issues"},"dist":{"shasum":"65dc3abbffad03959f155f03ca08509b0f2a850f","tarball":"https://registry.npmjs.org/@ethereum-waffle/ens/-/ens-4.0.3-dev.4541f86.tgz","fileCount":66,"integrity":"sha512-Ia5W/GTE0tseq/O2Od4NH8OsFIB9OqT3IadD8AdFJUBQg1QBhnhnrpMw1GBKIRvH/c9kA8WphGyQ754H4TBS/Q==","signatures":[{"sig":"MEYCIQCzZ72/42LL71Vrq4Ff6A8ck08nIWOe7iC3C7A0uriXkAIhAMn2o2GbhcqIMntXXGVqAwn7N9rDctqjVGfr1w6EUeCT","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":2405933,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjX+2TACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpaIQ/7BEYIKxE6rKAIhF4ZabY5ukQiedCZ4TNrtTG202ed9U8Rtrc5\r\nuGvWh5BYAji3lEcsjdrWR4OjvpdLU9A0cVFYRYDIGpee80Ug2H1XPEmFmTKe\r\nmtqtRhGUtKDenxdmtXHpCD5Gz3V4gz2UI8ZAgYECBmm/WicaUNmrmPYuUK6N\r\noelA8GFL4APnyDwodi4DxyvzymFQDo6tGXukB8ohWsZNPQjp4Ube/0KC+1rF\r\nMIiDzbDoNI/3UJ9fAwWAeMnpUtlXxjHfKfSTvN4EhC1pR7lcXXgSf7DIL+7k\r\nzwog7Mfr+470CCyn/DI1K/7Fzy/qSmiGUjyyN9z1YuGp41cMaCGP+DYtaZhs\r\nWzngtK0nbpr+14lt6jjVnOn8G9q5ffjCzHoExGGTMxMemzIJvk3bdKwOHaA5\r\nUo+7wgSzE44/5kSBK6rYYDKj7VgWZY1aonKwOtvdMeTB9fdXVI4ofkzaWIUX\r\nah6gC48Nn8Ab06oLhKJa7eKlkzItBc0rodo0xBr4vCJxJf6QYf9B6nV2ouM+\r\nMqVK0/zRSYhtXxeS7xGcYJiZH61+3+ek4b+iTx9SSRadfxkLPjr8iCvfC9G0\r\nXny1/ghIFmBlKoVMDJ/k7JXSjWdzE0ZWqETATIUmKAjPV+ZSbqsR+4oEuark\r\ncnmN3TdOB2zCNsZ7NJOt3YbJXHE8+R8zTG0=\r\n=wnzK\r\n-----END PGP SIGNATURE-----\r\n"},"main":"dist/cjs/src/index.js","name":"@ethereum-waffle/ens","_from":"file:ethereum-waffle-ens-4.0.3-dev.4541f86.tgz","types":"dist/esm/src/index.d.ts","author":{"url":"http://ethworks.io","name":"Marek Kirejczyk","email":"account@ethworks.io"},"module":"dist/esm/src/index.ts","readme":"![CI](https://github.com/EthWorks/Waffle/workflows/CI/badge.svg)\n[![](https://img.shields.io/npm/v/@ethereum-waffle/ens.svg)](https://www.npmjs.com/package/@ethereum-waffle/ens)\n\n![Ethereum Waffle](https://raw.githubusercontent.com/EthWorks/Waffle/master/docs/source/logo.png)\n\n# @ethereum-waffle/ens\n\nA simple `ENS` for testing.\n\n## Installation\n\nIn the current version of waffle (v2.x.x) you will install this package as a dependency of the main waffle package - `ethereum-waffle`.\n\n```\nyarn add --dev ethereum-waffle\nnpm install --save-dev ethereum-waffle\n```\n\nIf you want to use this package directly, please install it via:\n```\nyarn add --dev @ethereum-waffle/ens\nnpm install --save-dev @ethereum-waffle/ens\n```\n\n## Feature overview\n\n**NOTE**: You do not need to use this package directly. You can install it through the main package (`ethereum-waffle`) and use it instead.\n\n### ENS\n\nThe `ENS` class allows to create ENS domains for testing.\n\nIt will deploy ENS smart contracts system to your test node.\n\nTo create `ENS`, you should submit your `wallet`, available in `MockProvider` class in package `@ethereum-waffle/provider`.\n\nYou can read more about ENS [in the ENS's documentation](https://docs.ens.domains/).\n\n### Examples:\nCreating ENS:\n```ts\nimport {MockProvider} from '@ethereum-waffle/provider';\nimport {deployENS, ENS} from '@ethereum-waffle/ens';\n\nconst provider = new MockProvider();\nconst [wallet] = provider.getWallets();\nconst ens: ENS = await deployENS(wallet);\n```\n\n### Usage\n\nUse `createTopLevelDomain` function to create a top level domain:\n\n```ts\nawait ens.createTopLevelDomain('test');\n```\n\nUse `createSubDomain` function for creating a sub domain:\n\n```ts\nawait ens.createSubDomain('ethworks.test');\n```\n\nAlso, it's possible to create a sub domain recursively, if the top domain doesn't exist, by specifying the appropriate option:\n\n```ts\nawait ens.createSubDomain('ethworks.tld', {recursive: true});\n```\n\nUse `setAddress` function for setting address for the domain:\n\n```ts\nawait ens.setAddress('vlad.ethworks.test', '0x001...03');\n```\nAlso, it's possible to set an address for the domain recursively, if the domain doesn't exist, by specifying the appropriate option:\n\n```ts\nawait ens.setAddress('vlad.ethworks.tld', '0x001...03', {recursive: true});\n```\n\nUse `setAddressWithReverse` function for setting address for the domain and make this domain reverse. Add recursive option if the domain doesn't exist:\n\n```ts\nawait ens.setAddressWithReverse('vlad.ethworks.tld', wallet, {recursive: true});\n```\n","engines":{"node":">=10.0"},"license":"MIT","private":false,"scripts":{"lint":"eslint '{src,test}/**/*.ts'","test":"mocha","build":"rimraf ./dist && pnpm build:artifacts && pnpm build:esm && pnpm build:cjs","lint:fix":"eslint --fix '{src,test}/**/*.ts'","build:cjs":"tsc -p tsconfig.build.json --outDir dist/cjs","build:esm":"tsc -p tsconfig.build.json --outDir dist/esm --module ES6","build:artifacts":"node build-artifacts.js"},"_npmUser":{"name":"ethworks","email":"code@trusttoken.com"},"homepage":"https://github.com/EthWorks/Waffle","keywords":["ethereum","smart-contracts","solidity","testing","javascript","typescript","library","ens"],"_resolved":"/tmp/b0d3e2115d138781da7a3cfe7431e375/ethereum-waffle-ens-4.0.3-dev.4541f86.tgz","_integrity":"sha512-Ia5W/GTE0tseq/O2Od4NH8OsFIB9OqT3IadD8AdFJUBQg1QBhnhnrpMw1GBKIRvH/c9kA8WphGyQ754H4TBS/Q==","repository":{"url":"git+ssh://git@github.com/EthWorks/Waffle.git","type":"git"},"_npmVersion":"8.15.0","description":"A mock ens implementation for testing.","directories":{},"maintainers":[{"name":"ethworks","email":"code@trusttoken.com"}],"_nodeVersion":"16.17.1","publishConfig":{"tag":"dev","access":"public"},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"mocha":"^8.2.1","eslint":"^7.14.0","ethers":"5.6.2","rimraf":"^3.0.2","ganache":"7.4.3","typescript":"^4.6.2","@ensdomains/ens":"^0.4.4","@ensdomains/resolver":"^0.2.4"},"peerDependencies":{"ethers":"*","@ensdomains/ens":"^0.4.4","@ensdomains/resolver":"^0.2.4"},"_npmOperationalInternal":{"tmp":"tmp/ens_4.0.3-dev.4541f86_1667231122954_0.9272077389766034","host":"s3://npm-registry-packages"},"_id":"@ethereum-waffle/ens@4.0.3-dev.4541f86","version":"4.0.3-dev.4541f86"}