PHP code example of protik / laravel-theme-switcher
1. Go to this page and download the library: Download protik/laravel-theme-switcher library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
protik / laravel-theme-switcher example snippets
->withMiddleware(function (Middleware $middleware): void {
$middleware->web(append: [
\Protik\ThemeSwitcher\Middleware\ApplyTheme::class,
]);
})
bash
php artisan vendor:publish --tag=config --provider="Protik\ThemeSwitcher\ThemeSwitcherServiceProvider"