bobbyt
11/14/2017, 7:45 PMconst newMessageSubscription = gql`
subscription {
Message(filter: { mutation_in: [CREATED, UPDATED] }) {
node {
id
text
createdAt
sentBy {
id
name
}
receivedBy {
id
name
}
}
}
}
`;
This works (data is returned) when a new message arrives or an existing message field is updated (i.e., text
field). However, if a subfield such as receivedBy
is updated on the server (indicating another user has read the message), the subscription does not return anything. Thanks in advance!nilan
11/15/2017, 1:43 PMbobbyt
11/15/2017, 2:49 PM