Category: Laravel, PHP, api

Here, we’ll learn how to generate fake data with factory & seed into database. After installation of laravel & composer successfully, first set up Database configuration in .env file

This command will create a migration file in database/migrations & a factory file in database/factories Now update the people_table with below code in database/migrations

Now update PersonTableSeeder file with below code
Newsletter

Get the latest Laravel/PHP jobs, events and curated articles straight to your inbox, once a week

Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge. Glimpse streamlines Laravel development by seamlessly deploying GitHub pull requests to preview environments with the help of Laravel Forge.
Fathom Analytics | Fast, simple and privacy-focused website analytics. Fathom Analytics | Fast, simple and privacy-focused website analytics.
Shirts painstakingly handcrafted by under-caffeinated developers. Shirts painstakingly handcrafted by under-caffeinated developers.
Community Partners