The Avatar component provides the ability to display an avatar for a user (or account or other entity).
It displays an uploaded image or Gravatar based on the email address. If no image is present, then it falls back to displaying initials.
If you're using the Authentication component, then the Avatar component will be automatically installed. If not, then you can follow the installation instructions below:
rails g instrumental:avatars
To insert a component into a view:
rails g instrumental:avatars:insert
Find all of your customization options (via local variables) in this file:
app/views/shared/components/_avatar.html.erb
I created Instrumental Components to make designing and building professional apps with Ruby on Rails easy, fast, and fun. I use it on all of my projects and I hope it helps you build something great.