Methods
-
static bowerInstall (cmpnt opt , options opt , spawnOptions opt )
-
Receives a list of
componentsand anoptionsobject to install through bower.The installation will automatically run during the run loop
installphase.Parameters:
Name Type Attributes Description cmpntString | Array <optional>
Components to install
optionsObject <optional>
Options to pass to
dargsas argumentsspawnOptionsObject <optional>
Options to pass
child_process.spawn. -
static installDependencies (options opt )
-
Runs
npmandbower, in sequence, in the generated directory and prints a message to let the user know.Parameters:
Name Type Attributes Description optionsObject <optional>
options
Properties
Name Type Attributes Default Description npmBoolean | Object <optional>
true whether to run
npm installor can be options to pass todargsas argumentsbowerBoolean | Object <optional>
true whether to run
bower installor can be options to pass todargsas argumentsyarnBoolean | Object <optional>
false whether to run
yarn installor can be options to pass todargsas argumentsskipMessageBoolean <optional>
false whether to log the used commands
Examples
this.installDependencies({ bower: true, npm: true });this.installDependencies({ yarn: {force: true}, npm: false }); -
static npmInstall (pkgs opt , options opt , spawnOptions opt )
-
Receives a list of
packagesand anoptionsobject to install through npm.The installation will automatically run during the run loop
installphase.Parameters:
Name Type Attributes Description pkgsString | Array <optional>
Packages to install
optionsObject <optional>
Options to pass to
dargsas argumentsspawnOptionsObject <optional>
Options to pass
child_process.spawn. -
static scheduleInstallTask (installer, paths opt , options opt , spawnOptions opt )
-
Combine package manager cmd line arguments and run the
installcommand.During the
installstep, every command will be scheduled to run once, on the run loop.Parameters:
Name Type Attributes Description installerString Which package manager to use
pathsString | Array <optional>
Packages to install. Use an empty string for
npm installoptionsObject <optional>
Options to pass to
dargsas argumentsspawnOptionsObject <optional>
Options to pass
child_process.spawn. ref https://nodejs.org/api/child_process.html#child_process_child_process_spawn_command_args_options -
static yarnInstall (pkgs opt , options opt , spawnOptions opt )
-
Receives a list of
packagesand anoptionsobject to install through yarn.The installation will automatically run during the run loop
installphase.Parameters:
Name Type Attributes Description pkgsString | Array <optional>
Packages to install
optionsObject <optional>
Options to pass to
dargsas argumentsspawnOptionsObject <optional>
Options to pass
child_process.spawn.