1. Go to this page and download the library: Download laradic/annotation-scanner library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
laradic / annotation-scanner example snippets
use Laradic\IconGenerator\Factory;
use Laradic\IconGenerator\IconGenerator;
$icons = new Factory;
$icons->addDefaultFonts();
$generator = $icons->createGenerator('font-awesome');
$generator->setIcons('android', 'car', 'html5', 'github');
// 16x16px, 32x32px, etc
$generator->setSizes(16, 32, 64, 128);
// add some material colors
$generator->addColor('#ef5350'); // red 400
$generator->addColor('#42A5F5'); // blue 400
$generator->addColor('#424242'); // grey 800
$generator->addColor(251, 94, 11); // RGB Also supported
$generator->setOutDir(__DIR__ . '/../generated');
$generator->generate($prefix);
$generator->generate();
use Laradic\IconGenerator\Factory;
use Laradic\IconGenerator\IconGenerator;
$icons = new Factory;
$icons->addDefaultFonts();
$generate = function (IconGenerator $generator, $prefix = '') {
// 16x16px, 32x32px, etc
$generator->setSizes(16, 32, 64, 128);
// add some material colors
$generator->addColor('#ef5350'); // red 400
$generator->addColor('#42A5F5'); // blue 400
$generator->addColor('#424242'); // grey 800
$generator->setOutDir(__DIR__ . '/../generated');
$generator->generate($prefix);
};
$fa = $icons->createGenerator('font-awesome');
$fa->setIcons('android', 'car', 'html5', 'github');
$generate($fa, 'fa-');
$found = $icons->createGenerator('foundation-general');
$found->setIcons([ 'checkmark', 'remove', 'mail', 'calendar' ]);
$generate($found, 'found-');
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.