graphql-client
graphql-client copied to clipboard
Typed, correct GraphQL requests and responses in Rust
Hi, thank's for this great library. First of all I'm new to rust and sorry if I missed something obvious here. I was working on a PR against this repo...
I am trying to make a generic function to send queries to a server: ```rust fn make_graphql_request(url: &str, query: &QueryBody) -> Response{ let client = reqwest::Client::new(); let mut res =...
Not sure if I'm just misunderstanding how this is supposed to work. I have a somewhat complicated type that I would like to send over GraphQL. No problem, I used...
``` error: proc-macro derive panicked --> src/lib.rs:14:10 | 14 | #[derive(GraphQLQuery)] | ^^^^^^^^^^^^ | = help: message: Extracting query path. The graphql attribute is missing ``` ``` error: proc-macro derive...
We could give better error messages if we were able to give locations (or even render the lines) in the query where the error occurred. On the other hand, the...
I'm seeing error messages like `operation type not in schema`. Getting the operation type name in there would be handy :) .
As far as I know there is no Rust library that can do this yet, although graphql-parser has a way this could be implemented. (I'll paste it here when I...
When using `#[derive(GraphQLQuery)]`, after compiling, if you change the query file or the schema file and run `cargo build` again, it would do nothing. This is because compiler is unaware...
Currently, using the same file and `selected_operation` in the custom derive does not work. The generated `const QUERY = ""...` is the same string for all the generated modules, re-using...
Sometimes a deserialization error would be better than having to deal with unknown types. It also allows enums to `impl Copy`.