Laravel - Package Development - Overriding Package Views
When you use the loadViewsFrom
method, Laravel actually registers two locations for your views: the application's resources/views/vendor
directory and the directory you specify. So, using the courier
package as an example, Laravel will first check if a custom version of the view has been placed in the resources/views/vendor/courier
directory by the developer. Then, if the view has not been customized, Laravel will search the package view directory you specified in your call to loadViewsFrom
. This makes it easy for package users to customize / override your package's views.