Replies: 1 comment 3 replies
-
What does this mean? |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
There is a problem: when changing route name in routes.php file, you need to change it in ziggy config file. And it has a solution: instead of doubling all needed routes in config, we need middleware or route facade macro-function, so it will be look like this:
Route::any('/logout', [AuthController::class, 'logout'])->name('logout')->toJs();
or
Route::any('/logout', [AuthController::class, 'logout'])->name('profile.logout')->middleware('ziggy');
I didn't go into details with this, but if this feature is welcomed, I may try to do some PR.
Beta Was this translation helpful? Give feedback.
All reactions