thecodingmachine/nodejs-installer
A Composer installer that fetches Node.js and npm and places them inside the vendor directory of a PHP project, skipping the download when Node.js is already installed. Binaries are exposed through vendor/bin, so build tools that expect npm can run from a Composer script. Version, target directory and download options are set in the extra section of composer.json.
Maintenance activity