You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As you can see the path is missing docs and the anchor is missing content prefixes.
Since magical creation methods are one of the more foundational bits of knowledge to acquire IMHO, it would be nice to have this link fixed to help people new to the package (such as me) to find the relevant information more quickly.
The text was updated successfully, but these errors were encountered:
Please find my PR attached to this issue.
I'm not 100% sure how to fix this for the prior versions of the docs. Would corresponding PRs help merging into v1, v2 and v3 branches?
Maybe this is a bit too cumbersome to do via PRs. It would be nice if a maintainer could do this with direct access to this repo. Thanks!
When the package cannot find such a method for a type given to the data object's from method. [...]
Am I correct assuming, that a magic creation method is selected by its parameter signature rather than its name etc.? Meaning that I can have a fromModelA(ModelA $model) as well as fromModelB(ModelB $model) methods on a single Data class and it will select the correct factory method to be used even though both Models extend Elqouent's Model class?
✏️ Describe the bug
On https://spatie.be/docs/laravel-data/v4/getting-started/quickstart#content-customizing-the-creation-of-a-data-object the link to the details of magic creation methods is broken.
This is the case for v1 docs throughout v4.
Actual (v4):
https://spatie.be/laravel-data/v4/as-a-data-transfer-object/creating-a-data-object#magical-creation
Expected (v4):
https://spatie.be/docs/laravel-data/v4/as-a-data-transfer-object/creating-a-data-object#content-magical-creation
As you can see the path is missing
docs
and the anchor is missingcontent
prefixes.Since magical creation methods are one of the more foundational bits of knowledge to acquire IMHO, it would be nice to have this link fixed to help people new to the package (such as me) to find the relevant information more quickly.
The text was updated successfully, but these errors were encountered: