Skip to content

Commit de8faf0

Browse files
committed
docs: add some links
1 parent 8611cde commit de8faf0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

examples/northwind/schema.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ import { autoResetDataIn30min } from './wrappers/autoResetDataIn30min';
2323
import { seedByName } from '../../scripts/seedHelpers';
2424
import { FunctifiedAsync } from './FunctifiedAsync';
2525

26+
// see more PubSubs here https://www.apollographql.com/docs/apollo-server/data/subscriptions/#pubsub-implementations
2627
const pubsub = new PubSub();
2728

2829
const ViewerTC = schemaComposer.getOrCreateOTC('Viewer');
@@ -128,6 +129,8 @@ schemaComposer.Subscription.addFields({
128129
orderUpdated: {
129130
type: OrderTC,
130131
// way 2: load Order in AsyncIterator
132+
// in same manner you may use `withFilter` helper:
133+
// https://www.apollographql.com/docs/apollo-server/data/subscriptions/#subscription-filters
131134
resolve: (order) => order,
132135
subscribe: () =>
133136
FunctifiedAsync.map(pubsub.asyncIterator(['ORDER_UPDATED']), (_id) => {

0 commit comments

Comments
 (0)