1. Go to this page and download the library: Download boomdraw/laravel-helpers 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/ */
boomdraw / laravel-helpers example snippets
return [
/*
* Path to generate helpers in your app folder
*/
'path' => 'Helpers',
/*
* Dir for facades if you want to store them separately
* If empty, facades will be generated in path with Facade postfix
*/
'facade_dir' => null,
/*
* Key to store helpers in cache
*/
'cache_key' => 'helpers_cache',
/*
* Writes services to cache automatically
*/
'force_cache' => false,
];
bash
php artisan helpers:cache
bash
php artisan helpers:clear
bash
php artisan make:helper {class}
php
use BoomDraw\Helpers\Traits\RouteKeyGetter.php
php
use BoomDraw\Helpers\Traits\ServiceNameGetter.php
php
use BoomDraw\Helpers\Traits\TableNameGetter.php