Extend Laravel 5 Response Facade

风流意气都作罢 提交于 2019-12-04 17:06:32

Go to project root folder and in the terminal type

composer dump-autoload

Everything should be fine then. When you create a new folder, composer does not know about it, so it can not autoload files from it, even if they are psr-4 namespaced.

EDIT Also you need to declare alias for your facade in config/app.php under aliases array, not the providers one:

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