1.0.0-beta.2
This release includes a small breaking change because we switched from PHP-HTTP to PSR-18, its successor. Almost all PHP-HTTP clients now implement PSR-18, so this should not be a big problem. This also means for example that PSR exceptions are thrown instead of PHP-HTTP exceptions. If you are relying on some PHP-HTTP classes yourself, make sure to review your code and change those to their PSR equivalent. If you are using this package within a Laravel application, it is important to note that we also changed the way how you can bind your own HTTP client. Please see the documentation and compare all code changes for more details!
Added
- Added support for Laravel 6 #61.
Changed
- Switched from PHP-HTTP to PSR-18, its successor #60.
- The
\Swis\JsonApi\Client\Client
now uses php-http/discovery itself instead of the service provider. This should make usage without Laravel easier #60. - Removed the
$baseUri
parameter from\Swis\JsonApi\Client\Client::__construct()
, use\Swis\JsonApi\Client\Client::setBaseUri()
instead #60.
Removed
- Removed
\Swis\JsonApi\Client\Providers\ServiceProvider::getHttpClient()
and\Swis\JsonApi\Client\Providers\ServiceProvider::getMessageFactory()
as the client now discovers these classes itself. Custom HTTP clients must now be registered within your own service provider using a custom container binding #60.