Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save ChadTaljaardt/7de9d993605b033ad62a3b2e44a2bc5f to your computer and use it in GitHub Desktop.
Save ChadTaljaardt/7de9d993605b033ad62a3b2e44a2bc5f to your computer and use it in GitHub Desktop.
<?php
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
class ComposerServiceProvider extends ServiceProvider
{
/**
* Register bindings in the container.
*
* @return void
*/
public function boot()
{
// Using class based composers...
view()->composer(
'frontend.includes.header', 'App\Http\ViewComposers\HeaderComposer'
);
}
/**
* Register the service provider.
*
* @return void
*/
public function register()
{
//
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment