Skip to content

refactor(discussions): optimize graphql queries #861

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

Merged

Conversation

setchy
Copy link
Member

@setchy setchy commented Mar 7, 2024

This PR covers a few optimization items

  • combine graphql queries for discussion state and discussion url
  • extract function to perform filtering of results to a specific discussion node (reduce code duplication)
  • combine types
  • use client-side include directive to skip over-fetching comments/replies when not required
  • use graphql query variables instead of inline string building - closes refactor GraphQL queries to use query variables #830

@setchy setchy added the enhancement New feature or enhancement to existing functionality label Mar 7, 2024
@setchy
Copy link
Member Author

setchy commented Mar 7, 2024

coveralls does it again 😅

@setchy
Copy link
Member Author

setchy commented Mar 11, 2024

merge conflict resolved

@setchy
Copy link
Member Author

setchy commented Mar 15, 2024

@afonsojramos - would you mind re-reviewing this when you get a chance please. I've incorporated your previous feedback.

@setchy setchy added refactor Refactoring of existing feature and removed enhancement New feature or enhancement to existing functionality labels Mar 15, 2024
@afonsojramos afonsojramos merged commit d8ff03f into gitify-app:main Mar 18, 2024
@setchy setchy deleted the refactor/discussion-graphql-queries branch March 18, 2024 14:48
adufr pushed a commit to adufr/gitify that referenced this pull request Mar 25, 2024
@setchy setchy added this to the Release 5.0.0 milestone Jul 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
refactor Refactoring of existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

refactor GraphQL queries to use query variables
2 participants