F
Filament13mo ago
Jessy

how to get edit url for user profile?

->userMenuItems([ 'profile' => MenuItem::make() ->label('Edit profile') ->url(UserResource::getUrl('edit', ['record' => Auth::user()])). I tried this but got error: Target class [hash] does not exist.
Solution:
When you use this stuff in a Service Provider you need to wrap in in a Closure so that it's not evaluated right away, but when Filament needs it, because services aren't ready yet. ->userMenuItems(fn () => [...])...
Jump to solution
2 Replies
Solution
Dennis Koch
Dennis Koch13mo ago
When you use this stuff in a Service Provider you need to wrap in in a Closure so that it's not evaluated right away, but when Filament needs it, because services aren't ready yet. ->userMenuItems(fn () => [...])
Jessy
JessyOP13mo ago
Thanks
Want results from more Discord servers?
Add your server