fix(client): fix type errors of Client's methods #76
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is my attempt to solve the existing type errors of
client.ts
in #60.I merged
main
branch so it contains several commits (you can also update your branch), but the main changes are these two commits:I thought the existing type errors have come from two issues:
as
for the record object, making the output type invalid.as
, and also tried finding proper types fromlexicon.ts
and usingOutputOf
etc.<Query>
toClient
inagent.ts
.<Query>
but couldn't solve the type issue without removing it. But I feel like we could useClient
without the type parameter. I'm not sure if this is the correct fix or not. This solution may be invalid if we need to keep<Query>
. (feel free to dismiss in that case)