# gatsby-source-mathdroid-covid19

> Provides a Gatsby source plugin for the API made possible by mathdro.id's excellent work.

Latest version **0.2.0** (published 2020-03-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install gatsby-source-mathdroid-covid19
pnpm add gatsby-source-mathdroid-covid19
yarn add gatsby-source-mathdroid-covid19
bun add gatsby-source-mathdroid-covid19
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.0 |
| Published | 2020-03-16 |
| First published | 2020-03-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 95.7 KB |
| Known vulnerabilities | 0 (+25 in 1 direct dependencies) |
| Install scripts | no |
| Maintainers | freakyfelt |
| Keywords | gatsby, gatsby-source, covid19 |

## Links

- npm: https://www.npmjs.com/package/gatsby-source-mathdroid-covid19
- npm.io page: https://npm.io/package/gatsby-source-mathdroid-covid19

## Dependencies (3)

- [axios](https://npm.io/package/axios.md) ^0.19.2
- [luxon](https://npm.io/package/luxon.md) ^1.22.0
- [gatsby-core-utils](https://npm.io/package/gatsby-core-utils.md) ^1.0.33

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 0.2.0 (latest) — 2020-03-16
- 0.1.0 — 2020-03-15

## README

# gatsby-source-mathdroid-covid19

Provides a Gatsby source plugin for the API made possible by mathdro.id's excellent work.

## Getting Started

Add the plugin to your `gatsby-config.js` file along with a list of countries whose data you want to fetch (if any).

```js
module.exports = {
  ...
  plugins: [
    {
      resolve: 'gatsby-source-mathdroid-covid19',
      options: {
        countries: [{ iso2: 'DE' }],
      },
    }
  ]
}
```

From there you will have GraphQL nodes available like the following:

```gql
query MyQuery {
  covid19GlobalSummary {
    confirmed
    recovered
    deaths
    image
  }
  allCovid19CountrySummary {
    nodes {
      country
      confirmed
      recovered
    }
  }
  allCovid19ProvinceStateDetail(filter: {iso2: {eq: "US"}}, limit: 5, sort: {order: DESC, fields: [confirmed]}) {
    nodes {
      provinceState
      confirmed
      recovered
      deaths
    }
  }
}
```

### Plugin Options

See the Covid19PluginOptions type in src/nodes/types.ts

## Contributing

This plugin is still pretty barebones, so pull requests are more than welcome.

Ways to help

[] Get Jest up and running with some tests
[] Dynamically fetch data from the Gatsby GraphQL queries?
[] Make the Gatsby GraphQL nodes feel more native
[] Nest related data structures in GraphQL

## Supporting

Donate to mathdro.id or Johns Hopkins for their hard work

---
_Source: https://npm.io/package/gatsby-source-mathdroid-covid19 · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
