Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplicate api request when getPokemonByName query accept an object instead of string #3

Open
phongpt156 opened this issue Oct 19, 2022 · 3 comments

Comments

@phongpt156
Copy link

In getPokemonByName query i change param from name: string to object {name: string}, i got two api call when i first visit pokemon detail page.
Screen Shot 2022-10-20 at 00 40 22

@phongpt156 phongpt156 changed the title Duplicate api request when getPokemonByName accept an object params instead of string Duplicate api request when getPokemonByName query accept an object params instead of string Oct 19, 2022
@phongpt156 phongpt156 changed the title Duplicate api request when getPokemonByName query accept an object params instead of string Duplicate api request when getPokemonByName query accept an object instead of string Oct 19, 2022
@phryneas
Copy link
Owner

Well, did you change that both in the getServerSideProps function and the hook or only in one of both? Just a screenshot of the network tools is not really enough to help you I'm afraid.

@phongpt156
Copy link
Author

@phryneas I changed both in the getServerSideProps function and the hook.

@phongpt156
Copy link
Author

@phryneas Seem like the issue is from the next-redux-wrapper. I accidentally changed the version of next-redux-wrapper to 8.0.0

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

No branches or pull requests

2 participants