In test example,
methodArgs: {
last: {__variable__: 'last'}
},
variables: {
last: ''
},
types: {
last: 'LAST'
},
output: body: 'query test($last: LAST!) {\n testMethod(last: $last, last: $last){\n id\n\n }\n }',
don't know why passing a value in variables, it is useless. cuz variable's value is passed from outside of the graphql-tag, it only defines a name here. doc
actually, I don't think variables should be an object, It should be a keys array, cuz, it only define the variable types
so __variable__ is useless too, cuz we alway need define variable names with a named operation
now, the 'methodArgs', 'variables', 'types' design looks superfluous and not easy to use
maybe you should plan well
if keeping the variables still accept an object, I think the key:value <--- value should be an TYPE definition
I guess maybe you want the variable accept a default value? but seems it not work as expect
In test example,
don't know why passing a value in variables, it is useless. cuz variable's value is passed from outside of the graphql-tag, it only defines a name here. doc
actually, I don't think variables should be an object, It should be a keys array, cuz, it only define the variable types
so
__variable__is useless too, cuz we alway need define variable names with a named operationnow, the 'methodArgs', 'variables', 'types' design looks superfluous and not easy to use
maybe you should plan well
if keeping the variables still accept an object, I think the key:value <--- value should be an TYPE definition
I guess maybe you want the variable accept a default value? but seems it not work as expect