Correct way to add additional middleware route groups
I have managed to get Jetstream's "EmailVerified" functionality working with Filament by wrapping the resource and pages route groups around it in vendor/filament/filament/routes/web.php :
Obviously this isn't ideal, nor would be publishing the routes file (if that's even possible).
Is there a way I can achieve the same result by adding to the middleware section of the Filament config? Or some other place?
If so, what would be the syntax for this?
If I try and add the middleware route groups in my main web.php, it doesn't respect/know about the Filament ones.
2 Replies
Is there a way I can achieve the same result by adding to the middleware section of the Filament config?I think this is probably the way to go I believe 'verified' corresponds to
Illuminate\Auth\Middleware\EnsureEmailIsVerified
Yes! That works perfectly. Thanks! You're a superstar, @pboivin ! π