All notable changes to laravel-data
will be documented in this file.
- add values() on DataCollection by @Nielsvanpach in #135
- @Nielsvanpach made their first contribution in #135
Full Changelog: https://github.com/spatie/laravel-data/compare/1.4.7...1.5.0
- support $payload as a dependency in rules (#123)
- Add Dependency Injection for rules, messages, and attributes methods (#114)
- Add support for stdClass payload casting (#106)
- use present validation rule instead of required for data collections
- allow using default password config in password validation attribute (#94)
- solve binding issues on Laravel Octane (#101)
- fixes a bug where models nested by relation could not be created due to date casts
- add a
links
array to the paginated response - stop execution of
lazy::whenLoaded
closure when the relation isnull
- fix for aborting value assignment after a false boolean (#80)
- add a
WithoutValidation
attribute - allow transformers to target native types, data collections and data objects
- Allow transformers to target Data and DataCollections
- removes checks for built in types and
isBuiltIn
fromDataProperty
- add better support for defaults
- Laravel 9.x by @aidan-casey in #77
- Removes Spatie's Laravel Enums from dev requirements by @aidan-casey in #76
- @aidan-casey made their first contribution in #77
Full Changelog: https://github.com/spatie/laravel-data/compare/1.3.2...1.3.3
- add support for json_encode to Data objects
- add support for json_encode to DataCollection objects
- add basic support for intersection types
- allow casting of built in PHP types
- add support for inferring enum rules
- fix an issue where an Enum validation attribute would not work
- fixes the RequiredRuleResolver to support custom rules like
Enum
- add an Enum validation rule attribute
- rename the
authorized
method toauthorize
- disable the behavior were excluded conditional properties still could be included
- fix return type notice message
- fixes an issue where data object could not be created when it had lazy nested data object
- fixes windows test suite
- when creating data objects, we now will always run validation when a
Request
object is given not only when a data object is injected - removal of
DataFromRequestResolver
- added
DataValidatorResolver
- change data property types collection checking procedure
- move
spatie/test-time
dependency to require-dev - expand support for nested data object creation (#19)
- expand support for annotating data collections
- revert allow ignoring with a closure within a unique rule
- allow ignoring with a closure within a unique rule
- add a
WithData
trait for quicker getting data from objects
- fix required rules being added when not allowed
- initial release