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

Typescript types of variable inputs for cache read and write functions are incorrect #1129

Closed
m4tr1k opened this issue Jul 11, 2023 · 0 comments · Fixed by #1133
Closed

Typescript types of variable inputs for cache read and write functions are incorrect #1129

m4tr1k opened this issue Jul 11, 2023 · 0 comments · Fixed by #1133

Comments

@m4tr1k
Copy link
Contributor

m4tr1k commented Jul 11, 2023

Describe the bug

When using the Cache API, the requested variables for the query in Cache.read or Cache.write correspond to the $result type (instead of $input), which gives an error when using Typescript

Printscreen of the error:

Screenshot 2023-07-11 at 16 21 38

Severity

annoyance

Steps to Reproduce the Bug

  1. Make sure you have a query that requires variables to be passed through, and that you are using Typescript
  2. Use one of the Cache API methods: write or read
  3. When passing the variables to that function, you'll see a type error

Reproduction

No response

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

Successfully merging a pull request may close this issue.

1 participant