Blade view not reflecting changes

安稳与你 提交于 2019-11-30 02:57:59

In order to avoid the parsing of Blade files on each reload, Laravel caches the views after Blade is processed. I've experienced some situations where the source (view file) is updated but the cache file is not "reloaded". In these cases, all you need to do is to delete the cached views and reload the page.

The cached view files are stored in storage/framework/views.

Run this command from terminal

php artisan view:clear
Arthur Shlain

If you use PHPStorm, uncheck Preserve files timestamps deployment option: https://stackoverflow.com/a/42534996/2453148

Clear the cache and clear the cached blade files:

php artisan cache:clear
php artisan config:clear
php artisan view:clear

Alternatively if other suggested methods did not work, you can rename your files to different names. Refresh their corresponding web pages to start using new file name reference. Then you can rename the files back to your preferred names after the new pages to reflect their changes.

You can also check if opcache enabled, in that case you need to clear your opcache cache.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!