3.0.2 • Published 1 month ago

@supeffective/dataset v3.0.2

Weekly downloads
-
License
MIT
Repository
github
Last release
1 month ago

@supeffective/dataset

Pokémon JSON dataset for SuperEffective.gg based on Showdown's data.

It also includes a JavaScript HTTP client, data types and Zod schema validators.

Installation

npm install @supeffective/dataset
# or
yarn add @supeffective/dataset
# or
pnpm add @supeffective/dataset
# or
bun add @supeffective/dataset

Dev Server

This project includes a development server, to serve the data folder as a JSON API.

Optionally, it can also serve a directory of assets, such as images (e.g ../supereffective-assets/assets).

You can configure the server using the environment variables from the .env.example file.

To start the server, run pnpm dev, which will also rebuild the JS dist files whenever you change the TS files.

Adding new data

Here's a quick guide on how to add new data to the dataset for each data type. When you are finished, run pnpm build to rebuild the generated and the JS dist files.

The -index.json data files will be rebuilt automatically, using the data from the individual JSON files.

Adding new Pokémon

  • Add the Pokémon to data/pokemon-index.json (the id and region are enough)
  • Add the Pokémon JSON to data/pokemon/{region}/{pokemonId}.json (replace {region} and {pokemonId} with the actual values)
  • You can use any other as a template: data/pokemon/kanto/bulbasaur.json

Documentation

3.0.2

1 month ago

3.0.1

1 month ago

3.0.0

1 month ago

2.5.0

1 month ago

2.4.0

1 month ago

2.2.2

4 months ago

2.2.1

4 months ago

2.1.3

4 months ago

1.3.1

4 months ago

1.3.0

4 months ago

1.1.0

4 months ago

1.0.0

5 months ago

0.8.7

5 months ago

0.8.6

5 months ago

0.8.4

6 months ago

0.8.1

6 months ago

0.8.3

6 months ago

0.8.2

6 months ago

0.8.0

6 months ago

0.7.0

6 months ago

0.6.0

7 months ago

0.5.3

7 months ago

0.5.2

7 months ago

0.5.1

7 months ago

0.5.0

7 months ago

0.4.1

7 months ago

0.4.0

7 months ago

0.3.0

7 months ago

0.2.0

7 months ago

0.1.0

7 months ago