igaster / laravel-theme

Theme support for Laravel
MIT License
520 stars 113 forks source link

Suggestion to stop cache issues #104

Closed ghost closed 5 years ago

ghost commented 5 years ago

Very often me or my colleagues run into problems because theme's configs are being cached. Takes some time until we remember to clear off the cache. I want know what you think about this update to config/themes.php file:

// instead of 
'cache' => true,

// we do
'cache' => env('THEMES_CACHE', false),
igaster commented 5 years ago

I know that cache can be a problem because it will be forgotten.

So in my last commit, I defaulted it to false: https://github.com/igaster/laravel-theme/blob/master/src/Config/themes.php#L41

I agree with your solution, but I didn't want to create .env entries. You can publish the config file and change it as you suggested...

ghost commented 5 years ago

Its ok, I was looking for an opinion about my approach. 😄 Thanks!