A simple Laravel Theme Maker, enabled developers to create theme skeleton. Developers just need to add the middleware of themer after creating themes.
Run the following command to install the package:
composer require cleaniquecoders/themer
Register Themer service provider at config/app.php
in providers
key:
CleaniqueCoders\Themer\ThemerServiceProvider::class,
Register Themer middleware at the app/Http/Kernel.php
in $routeMiddleware
:
'theme' => \CleaniqueCoders\Themer\Http\Middleware\ThemeLoader::class,
php artisan make:theme your-theme-name
Route::get('home','HomeController@index')->middleware('theme:public');
OR
Route::group(['middleware' => ['theme:admin']], function(){
Auth:routes();
});
This package is open-sourced software licensed under the MIT license.