web.php adding new routes while having same function
route('login');
});
Route::get('/dashboard', function () {
return redirect()->route('products.index');
})->middleware(['auth', 'verified'])->name('dashboard');
Route::middleware('auth')->group(function () {
Route::resource('products', ProductController::class);
Route::get('/profile', [ProfileController::class, 'edit'])->name('profile.edit');
Route::patch('/profile', [ProfileController::class, 'update'])->name('profile.update');
Route::delete('/profile', [ProfileController::class, 'destroy'])->name('profile.destroy');
});
require __DIR__ . '/auth.php';
I want to know if adding new route to the line of code would still work within the parentheses, if there is a way to use it
also do not reply to these questions