# clanbite_avatar_badge_html()

The rank badge: a small shape (hexagon for hexagon avatars) at the avatar's lower right, holding the level icon or number.

Server rendering takes the data from `$badge`; Interactivity rendering passes `$bind` (a path to an `avatar_badge`
object) and the browser fills in the icon, number and label.

```php
clanbite_avatar_badge_html( string $shape, array $badge, string $bind = '' ): string
```

## Parameters

- `$shape` (string) `circle`, `square` or `hexagon`.
- `$badge` (array<string, mixed>) Data from `clanbite_get_avatar_badge()` (ignored when `$bind` is set).
- `$bind` (string) Interactivity path of the `avatar_badge` object, or empty for server rendering.

## Return

`string` Badge markup, or an empty string when there is nothing to show.

## Changelog

| Version | Description |
| --- | --- |
| 1.3.0 | Introduced |
