happy-github-dependents
v1.1.0
Published
Uses happy-dom to scrape GitHub dependents pages for a Github repository and generate a report sorted by stars in various formats (HTML, Markdown, CSV).
Maintainers
Readme
About
Uses Happy DOM to scrape GitHub dependents pages for a Github repository and generate a report sorted by stars in various formats (HTML, Markdown, JSON, CSV).
This tool doesn't require any API keys as it uses the public GitHub web interface to get the data.
Usage
Command Line
Example
npx happy-github-dependents --url=<repository_url>or
npx happy-github-dependents --url=<repository_url> --type=<html|markdown|json|csv> --output=<output_file>Arguments
| Argument | Description | Default value | Required |
| ---------- | --------------------------------------------------- | -------------------- | -------- |
| --url | URL of the GitHub repository | | Yes |
| --type | Output format: html, markdown, json, or csv | html | No |
| --output | Output file path | ./dependents.{ext} | No |
JavaScript
Example
import { getDependents } from "happy-github-dependents";
const dependents = await getDependents(
"https://github.com/capricorn86/happy-dom",
);
dependents.sort((a, b) => b.stars - a.stars);
console.log(dependents);