Laravel and Vendor Hi developper i was wondering if it's possible to move the vendor folder outside of the project and make it global for all the projects just like :
htdocs:
->vendor
->laravel_project 1
->larvel->project 2 ....etc.
if it's possible how can i force the composer to not install the vendor cause we allready have a vendor for all the projects .
Untested but I suppose you can move the vendor folder and composer.json to another directory and edit this line in index.php and artisan
require __DIR__.'/../vendor/autoload.php';
@sergiu17 Wont that clash if there are multiple composer.json files with different content? Or can composer manage this somehow?
Isn't this a bad idea? What if two or more Laravel projects needs a different version of a package? Can you update them independently?
yes it looks bad ...and installing vendor all the time for every project is bad too
Are all projects exactly the same with exactly the same packages?
I would say installing the vendor packages for every package is the opposite of bad. like @sinnbeck asks, if there are different needs for packages you will find yourself some nice collision when project one requires monkeystuff 1.0 but project two requires monkeystuff 2.0
Please sign in or create an account to participate in this conversation.