Skip to content

Commit 6b224b3

Browse files
committed
Add use serde_derive::* to generated modules
This fixes an issue in Rust 2018 Edition where the serde macros are not in scope in the generated modules.
1 parent 2c3c83a commit 6b224b3

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

graphql_client_codegen/src/codegen.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,8 @@ pub fn response_for_query(
145145
let response_derives = context.response_derives();
146146

147147
Ok(quote! {
148+
use serde_derive::*;
149+
148150
#[allow(dead_code)]
149151
type Boolean = bool;
150152
#[allow(dead_code)]

0 commit comments

Comments
 (0)