Releases: woohoolabs/yang
Releases · woohoolabs/yang
Release list
3.0.0
ADDED:
- Support for PSR-18
CHANGED:
- Increased minimum PHP version requirement to 7.4
- Declare nearly all property types
- #34:
JsonApiClientimplements PSR-18'sClientInterface - #33: Use
Psr\Http\Client\ClientInterfaceas type
REMOVED:
- Support for php-http/httplug v1
- The deprecated ClassHydrator
- The deprecated HydratorInterface
3.0.0-rc1
CHANGED:
- #33: Use
Psr\Http\Client\ClientInterfaceas type - Declare nearly all property types
REMOVED:
- Support for php-http/httplug v1
3.0.0-beta1
ADDED:
- #34:
JsonApiClientimplements PSR-18'sClientInterface
CHANGED:
- Increased minimum PHP version requirement to 7.4
- PSR-18 is used instead of HTTPlug
REMOVED:
- The deprecated ClassHydrator has been removed
- The deprecated HydratorInterface has been removed
2.3.2
ADDED:
- #31: Allow to set the
filterquery parameter directly
2.3.1
ADDED:
- Support for PHP 8
- Support for PHPUnit 9
2.3.0
ADDED:
- #28: Introduce
AttributeHydratorInterface
2.2.1
FIXED:
ClassDocumentHydrator::hydrateSingleResource()returns anobjectinstead ofstdClass
2.2.0
ADDED:
AbstractClassDocumentHydratoras a base class for custom hydrators
CHANGED:
- Increased minimum PHP version requirement to 7.2
ClassDocumentHydratoris no longer afinalclass
2.1.0
ADDED:
- #13:
DocumentHydratorInterfaceandClassDocumentHydratorin order to fix some issues with theHydratorInterfaceandClassHydrator - #15: New accessor and mutator methods for
WoohooLabs\Yang\JsonApi\Request\ResourceObject:id(),setId(),type(),setType(),attributes(),relationships()
DEPRECATED:
HydratorInterface: use theDocumentHydratorInterfaceinsteadClassHydrator: use theClassDocumentHydratorinstead
2.0.0
Changes since beta1:
CHANGED:
- Apply the Woohoo Labs. Coding Standard
Full change set:
ADDED:
- JSON:API 1.1 related features:
- Support for Profiles
- Support for
typelinks in errors
Document::errorCount()to easily count errors in the document- Support for defining a default value when using the
ResourceObject::attribute()method
CHANGED:
- Improve type-safety by eliminating
nullreturn values (BREAKING CHANGE):JsonApiResponse::document()throws an exception instead of returning null if the response doesn't contain a document.Document::primaryResources()throws an exception if the document is a single-resource or error documentDocument::primaryResource()throws an exception if the document is a collection or error document or the primary resource is missingDocument::resource()throws an exception instead of returning null if the requested resource is missingDocument::error()throws an exception instead of returning null if the document does not contain the requested errorRelationship::resources()throws an exception instead of returning an empty array if the relationship is a to-oneRelationship::resource()throws an exception instead of returning null if the relationship is a to-many or emptyRelationship::resourceBy()throws an exception instead of returning null if the requested resource is missingResourceObject::relationship()throws an exception instead of returning null if the requested relationship is missing
- Move errors, links, and resources to their own namespace (BREAKING CHANGE):
WoohooLabs\Yang\JsonApi\Schema\ErrortoWoohooLabs\Yang\JsonApi\Schema\Error\ErrorWoohooLabs\Yang\JsonApi\Schema\ErrorSourcetoWoohooLabs\Yang\JsonApi\Schema\Error\ErrorSourceWoohooLabs\Yang\JsonApi\Schema\LinktoWoohooLabs\Yang\JsonApi\Schema\Link\LinkWoohooLabs\Yang\JsonApi\Schema\ResourceObjectstoWoohooLabs\Yang\JsonApi\Schema\Resource\ResourceObjectsWoohooLabs\Yang\JsonApi\Schema\ResourceObjecttoWoohooLabs\Yang\JsonApi\Schema\Resource\ResourceObject
- Return separate classes instead of a general
Linksfor the different types of links (BREAKING CHANGE):DocumentLinkswhen usingDocument::links()ResourceLinkswhen usingResourceObject::links()RelationshipLinkswhen usingRelationship::links()ErrorLinkswhen usingError::links()
JsonSerializer::serialize()will throw aRequestExceptioninstead ofLogicExceptionif the body is of invalid type (BREAKING CHANGE)- Rename
JsonApitoJsonApiObject(BREAKING CHANGE) - Apply the Woohoo Labs. Coding Standard
REMOVED:
- The generic
Linkclass (BREAKING CHANGE)
FIXED:
- Issues with 0 when converting to array