2.0.2 • Published 1 year ago
@klevn/gql-client v2.0.2
# test.graphql
query world($pass: String!){
todoHistoryByPassword(password: $pass) {
_id
}
}
import GqlClient from "@klevn/gql-client"
const gql = new GqlClient({
url: "https://graphql.eu.fauna.com/graphql",
headers: {
"authorization": "Basic 123"
}
}, "./test.graphql")
gql.run("world", {
pass: "hello",
resolve: ["todoHistoryByPassword", "_id"]
}).then(console.log)