CodeIgniter Forums

Full Version: How to manually load composer libraries?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I installed some packages composer into /application/vendors. But seems all of the installed packages are loaded automatically, even if I just want to use one of them.
Is there any way to manually load only needed package?
There are ways depending on the package. But you would loose automatic updates.

Check another action first, reinstall the packages with --no-dev option, use these commands.

Code:
composer install --no-dev
Code:
composer update --no-dev

If within the packages there are tests, they and their dependencies would not be installed and the size of your vendor/ directory would get lower.
It's autoloading in the sense that you don't need to do include()s manually, not that everything is loaded at once.

Don't worry about it.
(01-30-2017, 02:36 PM)Narf Wrote: [ -> ]It's autoloading in the sense that you don't need to do include()s manually, not that everything is loaded at once.

Don't worry about it.


OK, I got it. Thank you.