Closed ricardofiorani closed 4 years ago
To be more precise and directly, I mean this class:
https://github.com/endroid/qr-code/blob/master/src/Response/QrCodeResponse.php
It should implement PSR-7's ResponseInterface
(https://www.php-fig.org/psr/psr-7/#33-psrhttpmessageresponseinterface) instead of extending Symfony's Symfony\Component\HttpFoundation\Response
Hi @ricardofiorani. The implementation here is indeed too much tied to Symfony so I was already planning to move it. It is now placed in the bundle. No further need to implement any PSR-7 interfaces in the core library as any bundle or integration is free to provide its own response implementation if needed. Thank you.
Today the QR-Code lib requires
symfony/http-foundation
, however, if you don't use Symfony but any other PSR-7, you will have rely onsymfony/http-foundation
to support the PSR-7.Ideally, this lib would support PSR-7 to be framework agnostic and interoperable. Then on the Symfony Bundle it would support PSR-7 via the
symfony/http-foundation