NodePackageManager
class NodePackageManager (View source)
Methods
__construct(NodePackageManager|null $packageManager = null)
Create a new NodePackageManager manager instance.
string
getExecCommand(string $command)
Get the command to execute a package using the detected package manager.
string
getRunCommand(string $command)
Get the command to run a script using the detected package manager.
packageManager()
Get the Node package manager in use.
detect()
Detect the current package manager.
Details
__construct(NodePackageManager|null $packageManager = null)
Create a new NodePackageManager manager instance.
string
getExecCommand(string $command)
Get the command to execute a package using the detected package manager.
string
getRunCommand(string $command)
Get the command to run a script using the detected package manager.
NodePackageManager
packageManager()
Get the Node package manager in use.
protected NodePackageManager
detect()
Detect the current package manager.