orchestral / avatar by crynobone

Avatar Component for Orchestra Platform
110,324
8
3
Package Data
Maintainer Username: crynobone
Maintainer Contact: crynobone@gmail.com (Mior Muhammad Zaki)
Package Create Date: 2014-05-13
Package Last Update: 2021-04-18
Home Page: http://orchestraplatform.com/docs/latest/components/avatar
Language: PHP
License: MIT
Last Refreshed: 2024-03-23 03:08:16
Package Statistics
Total Downloads: 110,324
Monthly Downloads: 487
Daily Downloads: 12
Total Stars: 8
Total Watchers: 3
Total Forks: 2
Total Open Issues: 0

Avatar Component for Orchestra Platform

Avatar Component provide support for driver based avatar provider for your Laravel, PHP or Orchestra Platform application.

Build Status Latest Stable Version Total Downloads Latest Unstable Version License Coverage Status

Table of Content

Version Compatibility

Laravel | Avatar :--------|:--------- 5.5.x | 3.5.x 5.6.x | 3.6.x 5.7.x | 3.7.x 5.8.x | 3.8.x

Installation

To install through composer, simply put the following in your composer.json file:

{
    "require": {
        "orchestra/avatar": "^3.5"
    }
}

And then run composer install to fetch the package.

Quick Installation

You could also simplify the above code by using the following command:

composer require "orchestra/avatar=^3.5"

Configuration

Add Orchestra\Avatar\AvatarServiceProvider service provider in config/app.php.

'providers' => [

    // ...

    Orchestra\Avatar\AvatarServiceProvider::class,
],

You might also want to add Orchestra\Support\Facades\Avatar to class aliases in config/app.php:

'aliases' => [

    // ...

    'Avatar' => Orchestra\Support\Facades\Avatar::class,
],

Usage

You can easily display an avatar by passing a User instance.

<?php

$user = User::find(1);

$avatar = Avatar::user($user)->render();