https://matthewdaly.co.uk/blog/2022/10/02/everythings-potentially-a-callable/'Published by at 2nd October 2022 7:30 pm I'm a big fan of callables in PHP in general.
Job classes are something else that do only one thing, and thus it potentially makes sense to use an invokable class for them.
However, as with some of the other examples, it's not clear if it supports constructor injection, so it's best to check.
There are some limitations of using invokable classes which you should bear in mind when deciding whether to make a class an invokable or not.