0.1.0 • Published 3 years ago

gatsby-source-pokeapi v0.1.0

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

gatsby-source-pokeapi

A gatsby source plugin to fetch Pokemon data through the famous https://pokeapi.co/ API.

Installation

npm install gatsby-source-pokeapi

How to use

In your gatsby-config.js

module.exports = {
  plugins: [
    {
      resolve: `gatsby-source-pokeapi`,
      options: {
        nbOfPokemons: 251,
      },
    },
  ],
}

How to query

query {
  allPokemon {
    nodes {
      name
      stats {
        attack
        defense
        special_attack
        hp
        special_defense
        speed
      }
      types
    }
  }
}

License

This project is under the MIT license.

0.1.0

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago