This repository was archived by the owner on May 17, 2025. It is now read-only.

Description
When need send message, how to filter the target to get data?
I only find follow code
async filter(root, args, context) { return { error: false, } },
for example, is there have like pubsub.asyncIterator(triggers).next()to find the target?
import { withFilter } from 'graphql-subscriptions'
subscribe: withFilter(
() => pubsub.asyncIterator('NEW_MESSAGE'),
(payload, variables) => {
console.log('---------------messageFeed start-------------------')
console.log('::Subscription subscribe payload 发消息方:%s \nvariables 订阅收消息方:%s', payload, variables)
Then, When i get payload and variables data, i can compare if neet subscription message.