database/seeders/ProductSeeder.php
/**
     * Run the database seeds.
     *
     * @return void
     */
Run the database seeds.
@return void
Run the database seeds . @return void
public function run()
    {
        Product::factory(30)
            ->has(Review::factory(3), 'reviews')
            ->create();
    }
public function run ( ) { Product :: factory ( 30 ) -> has ( Review :: factory ( 3 ) , 'reviews' ) -> create ( ) ; }
Run the database seeds.
Run the database seeds .