File: D:/HostingSpaces/SBogers10/blije-gasten.komma.pro/app/Komma/Questions/QuestionComposer.php
<?php
namespace App\Komma\Questions;
use Illuminate\View\View;
final class QuestionComposer
{
/**
* Bind data to the view.
*
* @param View $view
* @return void
*/
public function compose(View $view)
{
/** @var QuestionService $questionService */
$questionService = app(QuestionService::class);
$questionsByCategories = $questionService->getQuestionsByCategory();
$view->with('composedQuestionsByCategories', $questionsByCategories);
}
}