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

Produce run-time error if client type does not match the definition from server #30

Open
anton-k opened this issue Oct 19, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@anton-k
Copy link
Owner

anton-k commented Oct 19, 2023

We can define any type suitable for clients and make a client for it with toClient function.
No error will prevent us from convertion to wrong type. From server definition we take only info on
path structure. Although we can augment it with info from RouteInfo and compare it at runtime with
things that we get from the client route type. And if they do not match we can try to warn user and produce run-time error.
It's some safety against blunder errors.

@anton-k anton-k added the enhancement New feature or request label Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant