Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 8f64f04

Browse filesBrowse files
committed
minor #16331 [Mercure] fix some typos and outdates sentences (dunglas)
This PR was merged into the 5.3 branch. Discussion ---------- [Mercure] fix some typos and outdates sentences Commits ------- 742b475 [Mercure] fix some typos and outdates sentences
2 parents 62667c8 + 742b475 commit 8f64f04
Copy full SHA for 8f64f04

File tree

Expand file treeCollapse file tree

1 file changed

+12
-12
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+12
-12
lines changed

‎mercure.rst

Copy file name to clipboardExpand all lines: mercure.rst
+12-12Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,14 @@ This secret key must be stored in the ``MERCURE_JWT_SECRET`` environment variabl
112112
MercureBundle will use it to automatically generate and sign the needed JWTs.
113113

114114
In addition to these environment variables,
115-
MercureBundle provides a more advanced configuration configuration:
115+
MercureBundle provides a more advanced configuration:
116116

117-
* ``secret``: the key to use to sign the JWT (all other options, beside `algorithm`, `subscribe`, and `publish` will be ignored)
118-
* ``publish``: a list of topics to allow publishing to when generating the JWT (only usable when `secret`, or `factory` are provided)
119-
* ``subscribe``: a list of topics to allow subscribing to when generating the JWT (only usable when `secret`, or `factory` are provided)
120-
* ``algorithm``: The algorithm to use to sign the JWT (only usable when `secret` is provided)
117+
* ``secret``: the key to use to sign the JWT (all other options, beside ``algorithm``, ``subscribe``, and ``publish`` will be ignored)
118+
* ``publish``: a list of topics to allow publishing to when generating the JWT (only usable when ``secret``, or ``factory`` are provided)
119+
* ``subscribe``: a list of topics to allow subscribing to when generating the JWT (only usable when ``secret``, or ``factory`` are provided)
120+
* ``algorithm``: The algorithm to use to sign the JWT (only usable when ``secret`` is provided)
121121
* ``provider``: The ID of a service to call to provide the JWT (all other options will be ignored)
122-
* ``factory``: The ID of a service to call to create the JWT (all other options, beside `subscribe`, and `publish` will be ignored)
122+
* ``factory``: The ID of a service to call to create the JWT (all other options, beside ``subscribe``, and ``publish`` will be ignored)
123123
* ``value``: the raw JWT to use (all other options will be ignored)
124124

125125
.. configuration-block::
@@ -186,7 +186,7 @@ MercureBundle provides a more advanced configuration configuration:
186186
187187
.. tip::
188188

189-
The JWT payload must contain at least the following structure to be allowed to
189+
The JWT payload must contain at least the following structure for the client to be allowed to
190190
publish:
191191

192192
.. code-block:: json
@@ -338,8 +338,8 @@ in a ``Link`` HTTP header.
338338

339339
.. image:: /_images/mercure/discovery.png
340340

341-
You can create ``Link`` headers with the :doc:`WebLink Component </web_link>`,
342-
by using the ``AbstractController::addLink`` helper method::
341+
You can create ``Link`` headers with the ``Discovery`` helper class
342+
(under the hood, it uses the :doc:`WebLink Component </web_link>`)::
343343

344344
// src/Controller/DiscoverController.php
345345
namespace App\Controller;
@@ -416,10 +416,10 @@ of the ``Update`` constructor to ``true``::
416416
}
417417

418418
To subscribe to private updates, subscribers must provide to the Hub
419-
a JWT containing a topic selector matching by the update's topic.
419+
a JWT containing a topic selector matching by the topic of the update.
420420

421421
To provide this JWT, the subscriber can use a cookie,
422-
or a ``Authorization`` HTTP header.
422+
or an ``Authorization`` HTTP header.
423423

424424
Cookies can be set automatically by Symfony by passing the appropriate options
425425
to the ``mercure()`` Twig function. Cookies set by Symfony are automatically
@@ -470,7 +470,7 @@ Programmatically Setting The Cookie
470470

471471
Sometimes, it can be convenient to set the authorization cookie from your code
472472
instead of using the Twig function. MercureBundle provides a convenient service,
473-
:class:`Symfony\\Component\\Mercure\\Authorization`, to do so.
473+
``Authorization``, to do so.
474474

475475
In the following example controller, the added cookie contains a JWT, itself
476476
containing the appropriate topic selector.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.