fipamo/routes/web.php
ro 9c200ea78d
reorganized text editor
moved page meta data to it's own ui to clean up the page editing
experience as it was becoming a bit crowded.

also moved to saving and deleting buttons to title bar so they are
always available

added a note to web routes to reorganize them within the web routes file
to reduce the confusion present by having them in their own Controllers.
it's just an extra layer that's not needed
2025-05-12 13:12:58 -06:00

28 lines
1.2 KiB
PHP

<?php
use Illuminate\Support\Facades\Route;
use App\Http\Controllers\RouteGetController;
use App\Http\Controllers\RoutePostController;
use App\Http\Controllers\RoutePutController;
use App\Http\Controllers\RouteDeleteController;
use App\Http\Middleware\VerifyCsrfToken;
/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider and all of them will
| be assigned to the "web" middleware group. Make something great!
|
*/
//REFACTOR: Reorganize routes here intstead of controllers to reduce confusion
Route::get("/{first?}/{second?}/{third?}/{four?}", [RouteGetController::class, 'handleRequest']);
Route::post("/{first?}/{second?}/{third?}", [RoutePostController::class, 'handleRequest'])
->middleware(VerifyCsrfToken::class);
Route::put("/{first?}/{second?}/{third?}", [RoutePutController::class, 'handleRequest'])
->middleware(VerifyCsrfToken::class);
Route::delete("/{first?}/{second?}/{third?}", [RouteDeleteController::class, 'handleRequest'])
->middleware(VerifyCsrfToken::class);