middleware(['throttle:credentials'])->group(function () { Route::get('/', function () { return redirect()->route('home'); }); // * API Route. Route::get('stores/{city}', [StoreController::class, 'city'])->name('stores.city'); Route::localized(function () { Route::get('/', [HomeController::class, 'index'])->name('home'); /** @var \Illuminate\Translation\Translator */ $trans = trans(); Route::get($trans->uri('products'), [ProductController::class, 'index'])->name('products.index'); Route::get( $trans->uri('product/{publishedProduct:slug}'), [ProductController::class, 'show'] )->name('product.show'); Route::get($trans->uri('recipes'), [RecipeController::class, 'index'])->name('recipes.index'); Route::get( $trans->uri('recipes/{publishedRecipe:slug}'), [RecipeController::class, 'show'] )->name('recipe.show'); Route::get($trans->uri('storefinder'), function () { return view('fo.pages.storefinder'); })->name('storefinder.index'); Route::get($trans->uri('contact-us'), [ContactController::class, 'contactForm'])->name('contact-form'); Route::post( $trans->uri('contact-us'), [ContactController::class, 'sendContactForm'] )->name('contact-form.send'); Route::get($trans->uri('legals'), function () { return view('fo.pages.legals'); })->name('legals'); Route::get($trans->uri('privacy'), function () { return view('fo.pages.privacy'); })->name('privacy'); Route::get( $trans->uri('concept/{concept:slug}'), [ConceptController::class, 'show'] )->name('concept.show'); }); });