In Laravel 5.0.27 I am including a view with with a variable and the following code:
@include(\'layouts.article\', [ \'mainTitle\' => \"404, page
You can pass a $data array
"404, page not found", 'mainContent' => "sorry, but the requested page does not exist :(" ] ?> @include('layouts.article', $data)
use $data['mainTitle'] etc in layouts.article
$data['mainTitle']
layouts.article