@cityofzion/neon-domain
TypeScript icon, indicating that this package has built-in type declarations

4.9.0 • Public • Published

neon-domain

Overview

Neon-Domain plugin. Provides the package domain within neon-js.

  • Provides functionality to resolve domain names to addresses.

Installation

yarn i @cityofzion/neon-domain
const neonCore = require("@cityofzion/neon-core");
const domainPlugin = require("@cityofzion/neon-domain");

const neonJs = domainPlugin(neonCore);

module.exports = neonJs;

API

In order to use the resolver, you must first create an instance of it using the scripthash:

const provider = neonJs.domain.nns.instance(contractScriptHash);

The resolver interface is defined in provider/common.ts.

You can resolve a domain by providing a rpc node url and the domain:

const blockchainAddress = provider.resolveDomain(rpcUrl, "myaddress.neo");

Package Sidebar

Install

npm i @cityofzion/neon-domain

Weekly Downloads

1

Version

4.9.0

License

MIT

Unpacked Size

23.9 kB

Total Files

51

Last publish

Collaborators

  • melanke
  • hal0x2328
  • ethanfast
  • snowypowers
  • rockacola
  • lllwvlvwlll