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

Optimize favorites page fetch requests #619

Merged
merged 10 commits into from
Jul 3, 2023

Conversation

Palakkgoyal
Copy link
Contributor

This PR closes issue no. #607
You can check the optimization by:

  • remove all posts from favorites then, reload the favorite page, it will take no time for the optimized version to load but, very much for the unoptimized one.
  • try the same thing by adding some posts to favorites, optimized version will take less time than the other one.

@narayan954 narayan954 linked an issue Jul 2, 2023 that may be closed by this pull request
Copy link
Owner

@narayan954 narayan954 left a comment

Choose a reason for hiding this comment

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

favourite page is giving error, can you try fixing that?
Uncaught TypeError: Cannot destructure property 'caption' of 'post' as it is undefined

src/components/Favorite.jsx Outdated Show resolved Hide resolved
src/components/Favorite.jsx Outdated Show resolved Hide resolved
src/components/Favorite.jsx Outdated Show resolved Hide resolved
@Palakkgoyal
Copy link
Contributor Author

Okay. Going to fix these bugs.

@Palakkgoyal
Copy link
Contributor Author

Palakkgoyal commented Jul 3, 2023

favourite page is giving error, can you try fixing that? Uncaught TypeError: Cannot destructure property 'caption' of 'post' as it is undefined

Hey @narayan954 I fixed the console.log and also given a default value to the savedPostsArr but, I am not getting any error as you said related to caption.

@narayan954
Copy link
Owner

favourite page is giving error, can you try fixing that? Uncaught TypeError: Cannot destructure property 'caption' of 'post' as it is undefined

Hey @narayan954 I fixed the console.log and also given a default value to the savedPostsArr but, I am not getting any error as you said related to caption.

reviewing :)

@narayan954
Copy link
Owner

favourite page is giving error, can you try fixing that? Uncaught TypeError: Cannot destructure property 'caption' of 'post' as it is undefined

Hey @narayan954 I fixed the console.log and also given a default value to the savedPostsArr but, I am not getting any error as you said related to caption.

see :/
image

@narayan954
Copy link
Owner

favourite page is giving error, can you try fixing that? Uncaught TypeError: Cannot destructure property 'caption' of 'post' as it is undefined

Hey @narayan954 I fixed the console.log and also given a default value to the savedPostsArr but, I am not getting any error as you said related to caption.

see :/ image

some posts are undefined, maybe that's because they're deleted?
image

Copy link
Owner

@narayan954 narayan954 left a comment

Choose a reason for hiding this comment

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

looks good to me!

@narayan954 narayan954 merged commit 9de4eae into narayan954:master Jul 3, 2023
@Palakkgoyal
Copy link
Contributor Author

Okay, got that its very necessary to check every aspect of code.

@narayan954
Copy link
Owner

Okay, got that its very necessary to check every aspect of code.

yes! :)

@Palakkgoyal Palakkgoyal deleted the optimizeFavorites branch July 4, 2023 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

Optimize favorite page requests
2 participants