MCPcopy Index your code
hub / github.com/ptmt/react-native-macos / add

Function add

local-cli/util/PackageManager.js:52–57  ·  view source on GitHub ↗

* Install package into project using npm or yarn if available * @param {[type]} packageName Package to be installed * @return {[type]} spawnSync's result object

(packageName)

Source from the content-addressed store, hash-verified

50 * @return {[type]} spawnSync's result object
51 */
52function add(packageName) {
53 return callYarnOrNpm(
54 `yarn add ${packageName}`,
55 `npm install ${packageName} --save`
56 );
57}
58
59/**
60 * Uninstall package from project using npm or yarn if available

Callers

nothing calls this directly

Calls 1

callYarnOrNpmFunction · 0.85

Tested by

no test coverage detected