Search documentation v1.0.0

Testimonial

Showcase positive feedback from users

Source Report Issue

Use the Testimonial component to showcase positive feedback or endorsements from customers, clients, or users.

Preview

"Add user testimonies to improve trustworthiness"

NicoleNicole WilliamsDeveloper
Unlock code
How to use the Testimonial component in Astro
<Testimonial
text='"Add user testimonies to improve trustworthiness"'
name="Nicole Williams"
role="Developer"
avatar={{
img: '/img/avatar2.png',
alt: 'Nicole'
}}
/>

To use the Testimonial component, you must specify a text and a name prop. You can also specify the following additional props to customize the look of your component:

With required props only

"Add user testimonies to improve trustworthiness"

Nicole Williams
Without icon

"Add user testimonies to improve trustworthiness"

NicoleNicole WilliamsDeveloper
Unlock code
No avatar will be displayed
<Testimonial
text='"Add user testimonies to improve trustworthiness"'
name="Nicole Williams"
/>
Unlock code
How to hide icon
<Testimonial
showIcon={false}
...
/>

API

Unlock code
Component API reference
type TestimonialProps = {
text: string
name: string
avatar?: AvatarProps
showIcon?: boolean
role?: string
className?: string
}
Please see the documentation of the Avatar component for AvatarProps.
PropPurpose
text Sets the text for the testimonial.
name Sets the name of the reviewer.
avatar Sets an avatar for the reviewer.
showIcon Shows a quote icon above the testimony.
role Sets the role of the reviewer.
className Pass additional CSS classes for the component.