I want to send lot of parameters to my query, and i don't want to define it. So i try to pass JSON parameter but i haven't lot of success with it.
I use the https://github.com/taion/graphql-type-json module.
This is my query definition :
usersByParams(params: JSON): [User]
My resolver is :
usersByParams: (_, { params }) => { console.log('PARAMS', params); return users; }
And my query is :
query getUsersByParams {
usersByParams(params: {test: 'this not work'}) {
id
firstName
lastName
email
password
}
}
I my resolvers i always fot "FALSE" value for params. I you have any tips for passing json Thank's