PHP code example of foryoufeng / laravel-generator

1. Go to this page and download the library: Download foryoufeng/laravel-generator 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/ */

    

foryoufeng / laravel-generator example snippets



return [
    'name' => 'Laravel Generator',
    // the url to access
    'route'=>'laravel-generator',
    // Define rules
    'rules' => [
        'string',
        'email',
        'file',
        'numeric',
        'array',
        'alpha',
        'alpha_dash',
        'alpha_num',
        'date',
        'boolean',
        'distinct',
        'phone',
        'custom'
    ],
    // Custom parameters
    'custom_keys'=>[
        'author'=>env('GENERATOR_AUTHOR','system')
    ]
];

php artisan generator:install
sh
php artisan vendor:publish --tag=laravel-generator