#303

The way you update a model from a Livewire Component is the same way how you update a model in Laravel.

For example in the submitForm() function in your Livewire component you can write the following:

public function submitForm()
{
Auth::user()->update([‘name’ => $this->name]);
}

You could also the same method
https://laravel.com/docs/10.x/eloquent#updates

but its a little more verbose and you have to import your User class

$user = User::where(‘name’, Auth::user()->name);

$user->name = $this -> name;

$user->save();