[PRO] PropertyForMorph should document as a constant value #1218
alec-superfile
started this conversation in
Ideas
Replies: 1 comment 5 replies
|
@alec-superfile doesn't it already document it like so? |
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
https://spatie.be/docs/laravel-data/v4/as-a-data-transfer-object/abstract-data
It would be amazing if Scramble could document the PropertyForMorph attribute as a constant for DTOs that extend an Abstract class. I'll also spend some time looking into how it can be made into an extension if possible.
Example:
Outputs to something like
It would be useful for our typescript clients to be able to narrow down which schema by checking the type instead of one of its unique properties.
All reactions