BlockieAvatar
Show a blockie (bar code profile icon) component for a given public address.
The autogenerated blockie can be manually replaced by another image that we pass through the ensImage prop.
If you want more control over styling the blockie, you can directly use blo (pre-installed in Scaffold-ETH 2) and internally used by BlockieAvatar component to get the image URL.
Importโ
import { BlockieAvatar } from "~~/components/scaffold-eth";
Usageโ
<BlockieAvatar address="0x34aA3F359A9D614239015126635CE7732c18fDF3" size={24} />
Propsโ
| Prop | Type | Default Value | Description |
|---|---|---|---|
address | string | undefined | The address for which you want to display its blockie. Ensure it's in the 0x___ format. |
size | number | undefined | Width and Height in pixels (square). |
ensImage (optional) | string | undefined | An arbitrary image url to render instead of the blockie. |