Skip to content

<Name />

The Name component is used to display ENS names associated with Ethereum addresses.

Usage

Address with an ENS:

import { Name } from '@coinbase/onchainkit/identity';
<Name address="0x02feeb0AdE57b6adEEdE5A4EEea6Cf8c21BeB6B1" /> 

Override styles

You can override component styles using className.

import { Name } from '@coinbase/onchainkit/identity';
<Name
  className="bg-emerald-400 px-2 py-1 rounded"
  address="0x02feeb0AdE57b6adEEdE5A4EEea6Cf8c21BeB6B1"
/>

Add attestation badge

Show attestation on ENV name with Badge component.

Use OnchainKitProvider or Identity component with the schemaId prop.

import { Badge, Name, Identity } from '@coinbase/onchainkit/identity'; 
 
<Identity
  schemaId="0xf8b05c79f090979bf4a80270aba232dff11a10d9ca55c4f88de95317970f0de9"
  address="0x838aD0EAE54F99F1926dA7C3b6bFbF617389B4D9"
>
  <Name>
    <Badge />
  </Name>
</Identity>

Props

NameReact