IconButton

The IconButton component is a <button> element with icon.

<IconButton
  name='flame'
  size={24}
  color='orange'
  title='Set on fire'
  onClick={() => {}}
/>

Be sure to include a title attribute for accessibility.

Props

PropTypeDescription
namestringIcon component name prop
legacybooleanIcon component legacy prop
colorstringIcon color
titlestringHTML title attribute
onClickfunctionSets a function to execute on click