What is the correct way to remove a package from Laravel using composer? So far I\'ve tried:
composer.json
(in "requir
To remove a package using composer command
composer remove <package>
To install a package using composer command
composer require <package>
To install all packages which are mentioned in composer.json
composer install
To update packages
composer update
I used these for Laravel project
Got it working... The steps to remove a package from Laravel are:
config/app.php
(reference in "providers" array)config/app.php
composer update vendor/package-name
. This will remove the package folder from the vendor
folder and will rebuild the composer autoloading map.It will remove the package folder from Vendor
folder
you can remove any package just by typing follwing command in terminal, and just remove the providers and alias you provided at the time of installing the package, if any and update the composer,
composer remove vendor/your_package_name
composer update
Before removing a package from composer.json declaration, please remove cache
php artisan cache:clear
php artisan config:clear
If you forget to remove cache and you get class not found error then please reinstall the package and clear cache and remove again.
**
use "composer remove vendor/package"
** This is Example: Install / Add Pakage
composer require firebear/importexportfree
Uninsall / Remove
composer remove firebear/importexportfree
Finaly after removing:
php -f bin/magento setup:upgrade
php bin/magento setup:static-content:deploy –f
php bin/magento indexer:reindex
php -f bin/magento cache:clean
You can remove any package by typing following command in terminal, and just remove the providers and alias you provided at the time of installing the package and update the composer
composer remove <package_name>
composer update