4.0.3 • Published 7 months ago

@ethereum-waffle/ens v4.0.3

Weekly downloads
12,252
License
MIT
Repository
github
Last release
7 months ago

CircleCI npm.io

Ethereum Waffle

@ethereum-waffle/ens

A simple ens builder for testing with ENS.

Installation

In the current version of waffle (v2.x.x) you will install this package as a dependency of the main waffle package - ethereum-waffle.

yarn add --dev ethereum-waffle
npm install --save-dev ethereum-waffle

If you want to use this package directly please install it via:

yarn add --dev @ethereum-waffle/ens
npm install --save-dev @ethereum-waffle/ens

Feature overview

NOTE: You do not need to use this package directly. You can install it through the main package (ethereum-waffle) and use it instead.

ENSBuilder

The ENSBuilder class allows to create ENS domains for testing.

It will deploy ENS smart contracts system to your test node.

To create ENSBuilder, you should submit your wallet, available in MockProvider class in package @ethereum-waffle/provider.

You can read more about ENS in the ENS's documentation.

Examples:

Creating of ENSBuilder:

import {MockProvider} from '@ethereum-waffle/provider';
import {createENSBuilder, ENSBuilder} from '@ethereum-waffle/ens';

const provider = new MockProvider();
const [wallet] = provider.getWallets();
const ensBuilder: ENSBuilder = await createENSBuilder(wallet);

Usage

Use createTopLevelDomain function to creating top level domain:

await ensBuilder.createTopLevelDomain('test');

Use createSubDomain function to creating sub domain for exiting domain:

await ensBuilder.createSubDomain('ethworks.test');

And use setAddress function for setting address for existing domain:

await ensBuilder.setAddress('vlad.ethworks.test', '0x001...03');
4.0.3-dev.238c11c

7 months ago

4.0.3-dev.efd5f2a

7 months ago

4.0.3

1 year ago

4.0.1

2 years ago

4.0.2

2 years ago

4.0.0-alpha.22

2 years ago

4.0.0-alpha.21

2 years ago

4.0.0-alpha.9

2 years ago

4.0.0-alpha.17

2 years ago

4.0.0-alpha.16

2 years ago

4.0.0-alpha.15

2 years ago

4.0.0-alpha.14

2 years ago

4.0.0-alpha.19

2 years ago

4.0.0-alpha.18

2 years ago

4.0.0-alpha.17.4

2 years ago

4.0.0-alpha.13

2 years ago

4.0.0-alpha.12

2 years ago

4.0.0-alpha.11

2 years ago

4.0.0-alpha.10

2 years ago

4.0.0-alpha.20

2 years ago

4.0.0-alpha.7

2 years ago

4.0.0-alpha.8

2 years ago

4.0.0-alpha.5

2 years ago

4.0.0-alpha.6

2 years ago

4.0.0-alpha.3

2 years ago

4.0.0-alpha.4

2 years ago

4.0.0-alpha.1

2 years ago

4.0.0-alpha.2

2 years ago

3.4.4

2 years ago

3.3.1

2 years ago

4.0.0-alpha.0

2 years ago

3.3.0

3 years ago

3.2.4

3 years ago

3.2.3

3 years ago

3.2.2

3 years ago

3.2.1

3 years ago

3.2.0

4 years ago

3.1.2

4 years ago

3.1.1

4 years ago

3.1.0

4 years ago

3.0.3

4 years ago

3.0.2

4 years ago

3.0.1

4 years ago

3.0.0

4 years ago

3.0.0-beta.3

4 years ago

3.0.0-beta.2

4 years ago

2.5.1

4 years ago

3.0.0-beta.1

4 years ago

2.5.0

4 years ago

2.4.1

4 years ago