@yunseorim1116/npm-pack-count
TypeScript icon, indicating that this package has built-in type declarations

0.1.9 • Public • Published

npm-pack-count

https://api.npmjs.org/downloads/point/${start}:${end}/${packageName} You can use that URL to get the number of npm package downloads.

const packages = ['a', 'b']

Goal

Basic functionality

  1. make it possible to get the number of downloads for multiple packages instead of just one package (ex: packages a, b)
  2. show total weekly and monthly package downloads by package. (ex: weekly package downloads of A, weekly package downloads of B)

option function

  1. shows the total weekly and monthly downloads of packages a and b combined.
  2. set the default option (one week from yesterday excluding the current date), You can also optionally input the desired weekly unit (ex: Monday-Sunday).
  3. Shows the total number of downloads for all packages.

Example for Use

(async () => {
  const tracker = new DownloadTracker(PACKAGES, 12);
  //The first argument is an array of package names, the second argument is the desired number of weeks
  const datas = await tracker.start();
  console.log(datas);
})();

Package Sidebar

Install

npm i @yunseorim1116/npm-pack-count

Weekly Downloads

0

Version

0.1.9

License

none

Unpacked Size

32.4 kB

Total Files

27

Last publish

Collaborators

  • yunseorim1116