Skip to content

faicchia/boring-avatars

Repository files navigation

Boring Avatars

Packagist Tests Style License

Generate boring avatars in PHP.

What is Boring Avatars?

Boring avatars is a tiny JavaScript React library that generates custom, SVG-based avatars from any username and color palette.

To know more go visit the official website

Installation

composer require faicchia/boring-avatars

Usage

use Faicchia\BoringAvatars\BoringAvatar;

$avatar = BoringAvatar::make()
    ->size(60)
    ->variant('bauhaus')
    ->name('James Smith')
    ->colors(['#2c5545', '#063971', '#2f353b'])
    ->url();
// https://source.boringavatars.com/bauhaus/60/James+Smith?colors=2c5545,063971,2f353b

Properties

Prop Type
size integer, 40px (default)
name string
variant oneOf: marble (default), beam, pixel,sunset, ring, bauhaus
colors array of colors

About

Generate boring avatars in PHP.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages