David Carrdcblogdev.hashnode.devยทNov 5, 2022Laravel update factory after creationUsing a Laravel factory to create a user and then update a relationship directly is possible using factory callbacks. Using a configure method you can call afterCreating and afterMaking closures: $this->faker->name(), 'slug' =>...344 readsfactoriesAdd a thoughtful commentNo comments yetBe the first to start the conversation.