Avatar
The Avatar component displays an avatar image for a given Ethereum address or ENS name, with support for fallback images.
Add to your project
import { Avatar } from 'ethereum-identity-kit'
export default function Home() {
return <Avatar address="0x1234...abcd" name="vitalik.eth" />
}
Parameters
Parameter | Description | Required | Default Value |
---|---|---|---|
address | The Ethereum address for the profile of the avatar. | Yes | - |
src | The source URL of the avatar image. | No | https://metadata.ens.domains/mainnet/avatar/{name} |
name | The ENS name of the avatar. | No | - |
fallback | The fallback image to display if the avatar image cannot be loaded. | No | https://ethfollow.xyz/assets/art/default-avatar.svg |
style | Inline styles to apply to the avatar. | No | - |
props | Additional props for the <div> element containing the avatar. | No | - |