Used to add a package to the project's `package.json`. Generally, this would be done from the `afterInstall` hook, to ensure that a package that is required by a given blueprint is available. @method addPackageToProject @param {String} packageName @param {String} target
(packageName, target)
| 1069 | @return {Promise} |
| 1070 | */ |
| 1071 | addPackageToProject(packageName, target) { |
| 1072 | let packageObject = { name: packageName }; |
| 1073 | |
| 1074 | if (target) { |
| 1075 | packageObject.target = target; |
| 1076 | } |
| 1077 | |
| 1078 | return this.addPackagesToProject([packageObject]); |
| 1079 | }, |
| 1080 | |
| 1081 | /** |
| 1082 | Used to add multiple packages to the project's `package.json`. |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…