Skip to content

Commit 0674414

Browse files
Use PSR-13 implementation from WebLink component
1 parent 95f4b91 commit 0674414

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

components/web_link.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ Usage
2222

2323
The following example shows the component in action::
2424

25-
use Fig\Link\GenericLinkProvider;
26-
use Fig\Link\Link;
2725
use Symfony\Component\WebLink\HttpHeaderSerializer;
26+
use Symfony\Component\WebLink\GenericLinkProvider;
27+
use Symfony\Component\WebLink\Link;
2828

2929
$linkProvider = (new GenericLinkProvider())
3030
->withLink(new Link('preload', '/bootstrap.min.css'));

mercure.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -283,10 +283,10 @@ by using the ``AbstractController::addLink`` helper method::
283283
// src/Controller/DiscoverController.php
284284
namespace App\Controller;
285285

286-
use Fig\Link\Link;
287286
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
288287
use Symfony\Component\HttpFoundation\JsonResponse;
289288
use Symfony\Component\HttpFoundation\Request;
289+
use Symfony\Component\WebLink\LInk;
290290

291291
class DiscoverController extends AbstractController
292292
{
@@ -383,12 +383,12 @@ And here is the controller::
383383
// src/Controller/DiscoverController.php
384384
namespace App\Controller;
385385

386-
use Fig\Link\Link;
387386
use Lcobucci\JWT\Builder;
388387
use Lcobucci\JWT\Signer\Hmac\Sha256;
389388
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
390389
use Symfony\Component\HttpFoundation\Request;
391390
use Symfony\Component\HttpFoundation\Response;
391+
use Symfony\Component\WebLink\Link;
392392

393393
class DiscoverController extends AbstractController
394394
{

web_link.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,10 +145,10 @@ You can also add links to the HTTP response directly from controllers and servic
145145
// src/Controller/BlogController.php
146146
namespace App\Controller;
147147

148-
use Fig\Link\GenericLinkProvider;
149-
use Fig\Link\Link;
150148
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
151149
use Symfony\Component\HttpFoundation\Request;
150+
use Symfony\Component\WebLink\GenericLinkProvider;
151+
use Symfony\Component\WebLink\Link;
152152

153153
class BlogController extends AbstractController
154154
{

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy