You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
GraphQL offers its own variables system. I always avoided it because it was verbose (π€¦ββοΈ) but it would actually offer a good solution to improper memoization:
api.v4(` repository (owner: $owner, name: $name) { name }`,{variables: getRepo()!})
Extract queries to .gql
Separately, I wonder if we could extract these queries to proper GQL files and then import them using a webpack loader.
The best advantage to this would be if there was a typescript transformer that actually parsed these files and provided types.
Webpack would only need to import them as raw text while TypeScript would receive proper types from these files so that we don't need to deal with any π
Formatting and validation would also be nice side effects of this.
Activity
fregante commentedon Jul 22, 2022
Maybe:
zoey-on-github commentedon Feb 22, 2023
is anyone else going to do this or can i work on it?
fregante commentedon Feb 22, 2023
You can work on the first part: allow variables. Don't try to fix all the current queries because some aren't possible