composer update all packages code example
Example 1: composer install production
composer install --no-dev --optimize-autoloader
Example 2: composer update single package
composer require phpmailer/phpmailer
composer install --no-dev --optimize-autoloader
composer require phpmailer/phpmailer