ReadOnlyTraitLaravel icon indicating copy to clipboard operation
ReadOnlyTraitLaravel copied to clipboard

Using native PHP readonly

Open michaelachrisco opened this issue 3 months ago • 0 comments

https://laravel-news.com/php-8-2-0#content-readonly-classes

Looks like PHP introduced readonly classes. Would it make sense to inherit that instead of having custom exceptions? It looks like it only works with dynamic properties not necessarily functions like save. Or you may get unintuitive errors.

michaelachrisco avatar Mar 27 '24 17:03 michaelachrisco