downloadNPMPackage

external fun downloadNPMPackage(options: DownloadNPMPackageOptions): Promise<dynamic>

Download an npm package. Returns "not_modified" when ifModifiedSince matches.

ifModifiedSince can be a version string, true to read the version from target/package.json, or a previous result object. The package is unpacked into target/package; target also holds the cached .tgz archive. Returns { downloadType: "npm", rootDir, contentsDir, version }.