Computed attribute redundancy when using multiple times #885
Unanswered
rudolfbruder
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I would like to ask a question regarding php attributes like #[Computed] used in spatie data.
Is there a way how to write it more efficiently? I have to specify it every time above each variable which can get tedious if you data has 30 computed attributes.
This is how I am doing it now:
How to achieve something like this - so that computed has to be defined only once?
I guess its a php thing not spatie data thing but maybe some of you figured it out.
Beta Was this translation helpful? Give feedback.
All reactions