<?php

namespace App\Http\Controllers\Login;

use Illuminate\Http\Request;

class RouteController extends Controller
{
    public function index(Request $request, $component = null)
    {
        $view = $component ? "login.{$component}" : 'login.default';
        if (!view()->exists($view)) {
            $view = 'login.default';
        }
        return view('login.route', compact('view'));
    }
}