public static function application(Application $app, $component, array $data = [], array $mergeData = []) { $appFolder = $app->getViewsFolder(); $viewName = config("my.{$appFolder}.views.{$component}", $component); $template = config(self::$configTemplate); $viewRoute = "{$template}.{$viewName}"; return view($viewRoute, $data, $mergeData); }