---
name: Avatar 头像
route: /avatar
parent: 组件
menu: 数据展示
---
import { Playground, Props } from 'docz'
import  Avatar  from '../components/avatar'


# Avatar 头像
>提示: 展开代码编辑器可以在线编辑，实时生效

## 基础用法

<Playground>
    <Avatar  width={90}/>
</Playground>


## propertyPath and actionUrl

通过propertyPath指定取返回结果的字段路径

<Playground>
    <Avatar actionUrl='http://www.mocky.io/v2/5d1da3e73000006800d72062' propertyPath='data.xxx.url'/>
</Playground>

## 图片属性限制

<Playground>
    <Avatar  sizeLimit={600} ratioLimit={[1,1]}/>
</Playground>


## API


<Props of={Avatar} />