# gh-calendar-scraper

> Scrapes a users GitHub contributions calendar

Latest version **1.0.1** (published 2022-08-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install gh-calendar-scraper
pnpm add gh-calendar-scraper
yarn add gh-calendar-scraper
bun add gh-calendar-scraper
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2022-08-15 |
| First published | 2022-08-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Unpacked size | 42.5 KB |
| Known vulnerabilities | 0 (+23 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Arsam Sarabi |
| Maintainers | arsamsarabi |
| Keywords | github, contributions, calendar, scraper |

## Links

- npm: https://www.npmjs.com/package/gh-calendar-scraper
- Repository: https://github.com/arsamsarabi/gh-calendar-scraper
- Issues: https://github.com/arsamsarabi/gh-calendar-scraper/issues
- npm.io page: https://npm.io/package/gh-calendar-scraper

## Dependencies (2)

- [axios](https://npm.io/package/axios.md) ^0.27.2
- [cheerio](https://npm.io/package/cheerio.md) ^1.0.0-rc.12

## Alternatives

- [@tsparticles/shape-image](https://npm.io/package/@tsparticles/shape-image.md) — 303.7K weekly downloads
- [@tsparticles/shape-line](https://npm.io/package/@tsparticles/shape-line.md) — 233.7K weekly downloads
- [stringify-attributes](https://npm.io/package/stringify-attributes.md) — 58.6K weekly downloads
- [mobile-drag-drop](https://npm.io/package/mobile-drag-drop.md) — 46.3K weekly downloads
- [@comunica/actor-rdf-parse-html](https://npm.io/package/@comunica/actor-rdf-parse-html.md) — 29.2K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2022-08-15
- 1.0.0 — 2022-08-15
- 0.0.1 — 2022-08-14

## README

# gh-calendar-scraper

Scrapes a users GitHub contributions calendar
![Github calendar example](/assets/calendar-example.png)

## Install

Install the package in your project.

```sh
$ yarn add gh-calendar-scraper
```

## Usage

Import the "fetchGithubCalendar" function and pass in a GitHub username.

```ts
import { GithubCalendar, fetchGithubCalendar } from 'gh-calendar-scraper'

const calendar: GithubCalendar = await fetchGithubCalendar('username')
```

## Types

Thit package also exports the following Typescript types:

```ts
type DayStats = {
  x: number
  y: number
  rx: number
  ry: number
  count: number
  date: string
  level: number
}

type GithubCalendar = Array<DayStats>
```

---
_Source: https://npm.io/package/gh-calendar-scraper · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
