type Message @withSubscription {
id: ID!
name: String!
text: String!
time: DateTime!
}
const handleDelete = ( ) => {
updateMessage({'variables': { "patch":
{ "filter": {
"text": ["sdf"]
},
"set": {
"text": "updated text"
}
}
} } );
}
const DELETE_MESSAGE = gql`
mutation updateMessage($patch: UpdateMessageInput!) {
updateMessage(input: $patch) {
message {
name
text
time
}
}
}
`;
response - Unhandled Rejection (Error): unknown field
or without ‘variables’
Unhandled Rejection (Error): must be defined
i think some error in Syntax but i cant find any examples on it mutations
can somebody help?