Skip to content

Avatar

Avatar is an image that represents a user or organization.

Work in progressWe are currently transferring the React documentation for Avatar from a different site to this page. To view the original documentation with code examples, please visit the Primer React documentation for Avatar.
  • @primer/react@35.24.0
  • Alpha
  • Not reviewed for accessibility

Import

import {Avatar} from '@primer/react'

Examples

View in Storybook

Props

Avatar

NameDefaultDescription
alt
''string

Provide alt text when the avatar is used without a name next to it.

size
20number

The size of the avatar in pixels.

square
falseboolean

If true, the avatar will be square instead of circular.

sx
SystemStyleObject