Skip to content

microvoid/retro-avatar

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

49 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

retro-avatar retro-avatar retro-avatar

retro-avatar

Create indenticon-like like Github and Gravatar (retro) avatars.

npm downloads NPM Version License

Features

  • Generate distinctive images for each user, enhancing recognizability.
  • Intuitive and easy to recognize.
  • Supports various themes.
  • All style options can be changed.

Documentation

For full documentation, visit website

Quick Start

You don't need to install any dependencies!

Just replace the ID_HERE placeholder with any text.

<img src="https://avatar.microvoid.io/api/avatar/ID_HERE" />

for example:

Options

Themes

theme usage demo
github https://avatar.microvoid.io/api/avatar/retro-avatar?t=github retro-avatar
gravatar https://avatar.microvoid.io/api/avatar/retro-avatar?t=gravatar retro-avatar
mono https://avatar.microvoid.io/api/avatar/retro-avatar?t=mono retro-avatar
mini https://avatar.microvoid.io/api/avatar/retro-avatar?t=mini retro-avatar
window https://avatar.microvoid.io/api/avatar/retro-avatar?t=window retro-avatar
mosaic https://avatar.microvoid.io/api/avatar/retro-avatar?t=mosaic retro-avatar

Size

size usage demo
32 https://avatar.microvoid.io/api/avatar/retro-avatar?s=32 retro-avatar
64 https://avatar.microvoid.io/api/avatar/retro-avatar?s=64 retro-avatar

The size must be between 16 and 2048, and default to 256.

Projects

Self host

  1. prerequires

retro-avatar rely on the node-canvas project, so you need to install its dependencies on your server.

for Ubuntu

sudo apt-get install build-essential libcairo2-dev libpango1.0-dev libjpeg-dev libgif-dev librsvg2-dev

for Fedora

sudo yum install gcc-c++ cairo-devel pango-devel libjpeg-turbo-devel giflib-devel

For other environments, please refer to node-cavas.

  1. clone project
git clone https://github.com/microvoid/retro-avatar.git
  1. deploy
sh deploy.sh
  1. environment variables (unnecessary)
# path: retro-avatar/apps/website/.env

# Google Analytics
NEXT_PUBLIC_ANALYTICS_ID=

# Logflare API
LOGFLARE_API_KEY=
LOGFLARE_API_TOKEN=