PHP code example of chinleung / laravel-factory-builder
1. Go to this page and download the library: Download chinleung/laravel-factory-builder 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/ */
chinleung / laravel-factory-builder example snippets
use Tests\Factories\UserFactory;
$user = app(UserFactory::class)->create();
use Facades\Tests\Factories\UserFactory;
$user = UserFactory::create();
bash
php artisan vendor:publish --provider="ChinLeung\Factories\FactoriesServiceProvider" --tag="config"