Type-graphql: Using Query-Complexity with ApolloServer and problem accessing req

Created on 27 May 2019  路  1Comment  路  Source: MichalLytek/type-graphql

Hi,

I have tried to add query-complexity to my typegraphql project as in the docs but when i add in the query complexity options to the ValidationRules on the server i can not access req object to pass through the req variables to the resolves. I am using ApolloServer for my base server. When i try and set variables: req.query.variables the req object is not available. I have followed the docs exactly. I wonder if anyone could advise on how to get query-complexity working with ApolloServer and typegraphql?

Thanks.

Out of scope Question

>All comments

Was this page helpful?
0 / 5 - 0 ratings

Related issues

limenutt picture limenutt  路  3Comments

Janushan picture Janushan  路  3Comments

oliversalzburg picture oliversalzburg  路  3Comments

laukaichung picture laukaichung  路  3Comments

MichalLytek picture MichalLytek  路  3Comments