Add very basic cache busting

This commit is contained in:
Dane Everitt 2018-02-18 15:15:53 -06:00
parent 1eb76c4457
commit 0341dbdfad
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
11 changed files with 135 additions and 76 deletions

View file

@ -203,7 +203,7 @@ return [
/*
* Additional Dependencies
*/
igaster\laravelTheme\themeServiceProvider::class,
Igaster\LaravelTheme\themeServiceProvider::class,
Prologue\Alerts\AlertsServiceProvider::class,
Lord\Laroute\LarouteServiceProvider::class,
],
@ -253,7 +253,7 @@ return [
'Schema' => Illuminate\Support\Facades\Schema::class,
'Session' => Illuminate\Support\Facades\Session::class,
'Storage' => Illuminate\Support\Facades\Storage::class,
'Theme' => igaster\laravelTheme\Facades\Theme::class,
'Theme' => Igaster\LaravelTheme\Facades\Theme::class,
'URL' => Illuminate\Support\Facades\URL::class,
'Validator' => Illuminate\Support\Facades\Validator::class,
'View' => Illuminate\Support\Facades\View::class,

View file

@ -2,10 +2,57 @@
return [
'enabled' => true,
'themes_path' => realpath(base_path('resources/themes')),
'asset_not_found' => 'LOG_ERROR',
'active' => env('APP_THEME', 'pterodactyl'),
/*
|--------------------------------------------------------------------------
| Root path where theme Views will be located.
| Can be outside default views path e.g.: resources/themes
| Leave it null if you will put your themes in the default views folder
| (as defined in config\views.php)
|--------------------------------------------------------------------------
*/
'themes_path' => realpath(base_path('resources/themes')),
/*
|--------------------------------------------------------------------------
| Set behavior if an asset is not found in a Theme hierarchy.
| Available options: THROW_EXCEPTION | LOG_ERROR | IGNORE
|--------------------------------------------------------------------------
*/
'asset_not_found' => 'LOG_ERROR',
/*
|--------------------------------------------------------------------------
| Do we want a theme activated by default? Can be set at runtime with:
| Theme::set('theme-name');
|--------------------------------------------------------------------------
*/
'default' => env('APP_THEME', 'pterodactyl'),
/*
|--------------------------------------------------------------------------
| Cache theme.json configuration files that are located in each theme's folder
| in order to avoid searching theme settings in the filesystem for each request
|--------------------------------------------------------------------------
*/
'cache' => true,
/*
|--------------------------------------------------------------------------
| Define available themes. Format:
|
| 'theme-name' => [
| 'extends' => 'theme-to-extend', // optional
| 'views-path' => 'path-to-views', // defaults to: resources/views/theme-name
| 'asset-path' => 'path-to-assets', // defaults to: public/theme-name
|
| // You can add your own custom keys
| // Use Theme::getSetting('key') & Theme::setSetting('key', 'value') to access them
| 'key' => 'value',
| ],
|
|--------------------------------------------------------------------------
*/
'themes' => [
'pterodactyl' => [
'extends' => null,