Install with composer
composer require deployer/recipes --dev
Add to your deploy.php
require 'recipe/npm.php';
bin/npm
(optional): set npm binary, automatically detected otherwise.
npm:install
– install npm packagesnpm:ci
– install npm packages with a new and "clean" node_modules directory
after('deploy:update_code', 'npm:install');
or if you want use npm ci
command
after('deploy:update_code', 'npm:ci');