Image
On this page
Image
Use the Image
component to display an image in your product. This renders the <img>
HTML element and extends the Box component.
Import component
import { Image } from 'rimble-ui';
Example
Props
alt
string
(optional)
Sets alt attribute on image for accessibility
as
(optional)
Default value:
'img'
height
(optional)
Default value:
'auto'
maxWidth
(optional)
Default value:
'100%'
src
string
(required)
Sets the src attribute of the img element
theme
object
(optional)
Styled System Props
Image
uses COMMON
, LAYOUT
, POSITION
, FLEXBOX
, BORDERS
groups of Styled System props.
Accessibility
- Always include an alt prop so that screen readers can describe the image to those with visual impairments