Laravel view edits triggering file_put_contents() permission denied fix

php artisan cache:clear 
composer dump-autoload
sudo chmod -R 775 storage/
sudo chgrp -R www-data storage bootstrap/cache
sudo chmod -R ug+rwx storage bootstrap/cache

More here and here