---
title: React Avatar（头像）组件
components: Avatar
---

# Avatars（头像）

<p class="description">在整个 material design 中，无论是在表格中还是到对话框菜单中，都可以找到使用头像的身影。</p>

## Image avatars（图片头像）

为了创建图像头像，您可以传递` src `或` srcSet `这样的标准的` img ` 的属性到组件里。

{{"demo": "pages/components/avatars/ImageAvatars.js"}}

## Letter avatars（字母头像）

为了创建包含简单字符的头像，您可以把字符串作为`子元素`来传递。

{{"demo": "pages/components/avatars/LetterAvatars.js"}}

## Icon avatars（图标头像）

为了创建图标头像， 您可以将图标作为`子元素`来传递。

{{"demo": "pages/components/avatars/IconAvatars.js"}}