condorrocks/condor

View on GitHub
app/Http/ViewComposers/NavLanguageComposer.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php

namespace App\Http\ViewComposers;

use Illuminate\View\View;

class NavLanguageComposer
{
    /**
     * Bind data to the view.
     *
     * @param View $view
     *
     * @return void
     */
    public function compose(View $view)
    {
        $view->with('availableLanguages', config('languages'));
        $view->with('appLocale', app()->getLocale());
    }
}