Skip to content

Conversation

climaxmba
Copy link
Contributor

@climaxmba climaxmba commented Mar 11, 2024

Update types declaration

This will extend the declaration to include the return type of the Promise returned in each method and some extra descriptions.

image

Previously, they were just plain Promise<object>.

@climaxmba climaxmba marked this pull request as ready for review March 13, 2024 06:11
@Naramsim
Copy link
Member

Thanks for your time! A question: how did you generate these changes? Did you do everything by hand? Or you used some kind of generator?

@climaxmba
Copy link
Contributor Author

climaxmba commented Mar 14, 2024

Thanks for your time!

You are very welcome, thanks for yours too.

A question: how did you generate these changes? Did you do everything by hand? Or you used some kind of generator?

Well, no. Initially I studied the Pokedex object using this repository's README and the browser's console, to write it.
Then I went through the declaration for pokedex-promise-v2 and copied most of what is seen in this PR. It is very precise and definitive. After that, I edited the things that were different, like the config to fit pokeapi-js-wrapper.

The file can also be generated with TypeScript or some NPM package, it won't include those extra writings that explains each property or object in a way that is preferred. But it can serve as a base.

Copy link
Contributor Author

@climaxmba climaxmba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Everything is set!

@Naramsim Naramsim merged commit efb9245 into PokeAPI:master Mar 27, 2024
@Naramsim
Copy link
Member

Thanks a lot!

@climaxmba
Copy link
Contributor Author

Anytime!

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants