Skip to content
APOORV SHRIVASTAVA edited this page Aug 2, 2024 · 3 revisions

npm-stats-viz

Deployed using gh-pages at this link: https://apoorv-x12.github.io/npm-stats-viz/

Overview

npm-stats-viz is a project that visualizes npm package download statistics. It uses the npm Downloads API to fetch and display download data for various npm packages.

Links

API Endpoints Used

npm Downloads API Endpoints

Endpoint Type URL Format Description
Total Downloads in a Period https://api.npmjs.org/downloads/point/:period/:package Retrieves the total downloads for a package over a specified period.
Total Downloads for a Specific Day https://api.npmjs.org/downloads/point/:date/:package Retrieves the total downloads for a package on a specific day.
Total Downloads for a Specific Range https://api.npmjs.org/downloads/range/:startDate:endDate/:package Retrieves the total downloads for a package over a specific date range.
Total Downloads for a Range with Stats https://api.npmjs.org/downloads/range/:period/:package Retrieves the total downloads for a package over a specified period with daily breakdowns.
Package Metadata https://registry.npmjs.org/:package Retrieves metadata for a specified package.

Example Responses

Total Downloads in a Period

{
  "downloads": 1234,
  "start": "2024-06-22",
  "end": "2024-06-23",
  "package": "string-utils-basic"
}

Technologies Used

  • Docker + NGINX: Containerization and serving of the static files.
  • React + TypeScript + Vite: Front-end development framework and build tool.
  • gh-pages: Deployment tool for hosting on GitHub Pages.