I want to create a server provider in Laravel.
I want this service provide to live under its own namespace.
Path\To\My\AwesomeServiceProvider
Where should I put this class? Normally I'd drop a custom class in
app/models
However, app/models
isn't added as an autoload source until after app/start/global.php
executes. This is too late for a service provider, as all service providers are registered in bootstrap/start.php
.
Is there a way to create a service provider without placing the class in composer's vendor
folder or monkeying with your composer.json
classmap?
Put another way, is there a location where Laravel will autoload classes from prior to bootstrap/start.php
being loaded that doesn't require additional composer configuration.
(For the inevitable "why don't you justs", the reason I want to avoid composer is I'm trying to figure out the bare minimum code and configuration needed for a service provider in Laravel)