Skip to content

Commit c182f86

Browse files
authored
Clarify subheadings under simple subscriptions only apply to simple subscriptions (#335)
1 parent bc0d08e commit c182f86

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/pages/postgraphile/subscriptions.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,8 @@ directly to test your application.
366366

367367
#### Topic prefix
368368

369+
**Note**: _this section only applies to "simple subscriptions."_
370+
369371
All topics requested from GraphQL are automatically prefixed with
370372
`postgraphile:`\* to avoid leaking other topics your application may be using
371373

@@ -477,6 +479,8 @@ Resulting in this GraphQL payload:
477479
478480
#### Subscription security
479481

482+
**Note**: _this section only applies to "simple subscriptions."_
483+
480484
By default, any user may subscribe to any topic, whether logged in or not, and
481485
they will remain subscribed until they close the connection themselves. This can
482486
cause a number of security issues; so we give you a method to implement security
@@ -535,6 +539,8 @@ terminated.
535539

536540
#### Naming your topics
537541

542+
**Note**: _this section only applies to "simple subscriptions."_
543+
538544
You might want to make the topic a combination of things, for example the
539545
subject type and identifier - e.g. 'channel:123'. If you do this then your
540546
function could determine which subject the user is attempting to subscribe to,
@@ -544,6 +550,8 @@ that will be published to in the event the user is kicked from the channel, e.g.
544550

545551
#### Example walk-through
546552

553+
**Note**: _this section only applies to "simple subscriptions."_
554+
547555
First, set up a `.postgraphilerc.js` containing the following:
548556

549557
```js

0 commit comments

Comments
 (0)